GUI to manage (essential) IceWM settings

Forum Forums antiX-development Development GUI to manage (essential) IceWM settings

Tagged: 

  • This topic has 122 replies, 14 voices, and was last updated Oct 18-8:59 am by PPC.
Viewing 15 posts - 1 through 15 (of 123 total)
  • Author
    Posts
  • #100441
    Member
    PPC

      Most IceWM settings can be changed from the menu or by right clicking the clock or the squares that present system information. But changing the clock that way does not “stick”, and the menu is too complex for ordinary users to understand, and there are too many options, most, really hard to understand.

      So I want to provide an easy GUI way to configure the system, all from a prefoverride file, that over rides the default settings.

      For now, I have a prefoverride config file that is heavilly commented and manages the most usual toolbar, clock and system info square options. Most values are easy to change, since they are “1” for “on” and “0” for “Off”. And there are only some dozen lines, not over a thousand (like the “preferences” file has).

      So, using your File Manager, go to ~/.icewm and make sure that a file called prefoverride exists there (if it does not exist, create it).

      Then you can paste the values you like, from the example file below.

      HOW TO:
      – Read the comments (the lines starting with #, to know what each option does)
      – Copy the values to your prefoverride text file. Save the file. Restart IceWM, to see the change.
      – Do you want to get back to the default settings? Rename or delete the prefoverride file and Restart IceWM

      The GUI I’m trying to create will manage only the features listed in this config file. I’m open to suggestions that are easy to implement.

      EDIT: the GUI will NOT manage Workspace options- Robin already took care of that – there’s a great GUI, over at the antiX-23 thread, that manages the numbers and names of workspaces on IceWM!!!

      
      #### This file overides options from the default Icewm Window Manager theme
      #### This file should be placed in ~/.icewm/
      #### ANY CHANGE YOU DO THE THIS CONFIG FILE REQUIRES YOU TO RESTART ICEWM: To enable any setting, change the value indicated after the equal sign (usually, you have two options: 1=on; 0=off and restart icewm (you can do that instantly by clicking (it's the same if you use a right click or a left click) the menu icon and then choose the last option ("exit" and then it's submenu - the right facinf arrow > select "Restart Icewm" OR, at the terminal run the command: "icewm --restart" (without quoation marks, of course)
      #
      #### IMPORTANT NOTE: in each line, everything after a "#" sign is ignored and considered just a comment (usually comments are there to show you the possible options or what they mean)
      ### How windows are displayed in the taskbar:
      #  Group applications with the same class name under a single task button: 0=off, 1=digits showing how many grouped windows, 2=dots, 3=both.
      TaskBarTaskGrouping=0 # [0-3]
      #  Show only icons of running windows on the toolbar (hide the title) - a larger number make the space that each window uses on the toolbar smaller. This setting is the only one that, to furfil it's end (when grouping windows of the same kind and showing, next to the icon, the number of windows, may require you to experiment with several possible values:
      TaskbarButtonWidthDivisor=18 #usually this setting is commented out (not used); to display just the icon (and not the title) default to "30"
      #  Taskbar justify left, right or center
      TaskBarJustify="center"
      ### Clock Settings:
      #  Clock: just show Hours:Minutes (to show Hours in am/pm format use: the value "%l:%M", for 24H use "%H:%M" (you can add ":%S" at the end to also see seconds), to add day of the mont*month: %d/%m
      TimeFormat=%H:%M 
      #  Clock font (in case it's not using the next preference: "TaskBarClockLeds=1"
      ClockFontName=”-*-monospace-medium-r-*-*-*-140-*-*-*-*-*-*”
      ClockFontNameXft=”monospace:size=12:bold”
      #  Task bar clock/battery monitor uses nice pixmap LCD display (but then it doesn't display correctly in many languages anymore, e.g., for Japanese and Korean it works only when a real font is used and not the LCD pixmaps
      TaskBarClockLeds=0 # 0/1
      ### Information gadgets about system resources (on the right, next to the clock)
      #  Show CPU status on task bar
      TaskBarShowCPUStatus=1
      #  Show memory usage status on task bar
      TaskBarShowMEMStatus=0 # 0/1
      #  Show network status on task bar
      TaskBarShowNetStatus=1 # 0/1
      #  Show battery status on task bar
      TaskBarShowAPMStatus=0 # 0/1
      ### Workspaces/virtual Desktops:
      #  To have multiple workspaces - just add a comma and it's name, inside quotation marks, for each extra workspace you want. Note: for the second workspace, you only need a comma, it will automaticly be named "2"
      #  To have only one workspace the line below should be: WorkspaceNames=" 1 "
      #  Inside the quotation marks, insert the name for each workspace, otherwise they will be numbered (the first one is " 1 ", etc)
      WorkspaceNames=" "
      #  Show workspace indicator on the task bar
      TaskBarShowWorkspaces=1 # 0/1
      ### Assorted taskbar settings (auto-hide, double height, move to the top of the screen)
      #  Autohide taskbar
      TaskBarAutoHide=0 # 0/1
      #  Taskbar at the top of the screen (instead of in the bottom)- PLEASE NOTE: FOR THIS TO BE PROPERLY ENABLE LOG OFF AND BACK ON:
      TaskBarAtTop=0
      # Taskbar with double height, useful to use taskbar as a "dock" to with many icons to quick-launch applications
      TaskBarDoubleHeight=0 # 0/1
      ### Title bar:
      #  Show app's icon on it's window's title bar:
      ShowMenuButtonIcon=1 # 0/1
      #### KEYBOARD SHORTCUTS:
      #  Tile windows with the Windows key + arrow keys shortcuts
      KeyWinTileLeft=Super+Left
      KeyWinTileRight=Super+Right
      KeyWinTileTop=Super+Up
      KeyWinTileBottom=Super+Down
      ###How to manage windows:
      #  Make new windows appear right below and to the right of the previous window (if CenterLarge=1 then this applies only to small windows, like galculator, etc)
      SmartPlacement=0 # 0/1
      # Make new large windows appear always in the center:
      CenterLarge=1 # 0/1
      # Show indication of position and window size, when dragging a window
      ShowMoveSizeStatus=0 # 0/1
      #  Pass focusing click on client area to client???
      #PassFirstClickToClient=0 # 0/1
      ### Stuff not handled in this config file:
      # Taskbar height it 's the height of "linux.xpm" (or the -xpm file used as Menu icon) in the theme that's being used
      # Titlebar height it's the field "TitleBarHeight" in theme that's being used. It can be set here, but doing that may mess up the way the tile bar looks...
      • This topic was modified 9 months, 1 week ago by PPC.
      • This topic was modified 9 months, 1 week ago by PPC.
      • This topic was modified 9 months, 1 week ago by PPC.
      #100447
      Moderator
      Brian Masinick
        Helpful
        Up
        0
        ::

        Yeah, that file is pretty big if you keep all of the comments in it.
        I decided to cut mine down considerably; here’s the current one.
        If anyone is interested, we can share the big one with the complete set of options.
        It has several hundred lines; one of them is in the 800-900 line range and
        that is why I cut mine down!

        UseMouseWheel=0 # 0/1
        AutoReloadMenus=1 # 0/1
        ShowTaskBar=1 # 0/1
        TaskBarAtTop=0 # 0/1
        TaskBarKeepBelow=0 # 0/1
        TaskBarAutoHide=0 # 0/1
        TaskBarShowClock=1 # 0/1
        TaskBarShowAPMAuto=1 # 0/1
        TaskBarShowMailboxStatus=0 # 0/1
        TaskBarShowWorkspaces=1 # 0/1
        TaskBarShowStartMenu=1 # 0/1
        TaskBarShowWindowListMenu=0 # 0/1
        TaskBarShowCPUStatus=1 # 0/1
        CPUStatusShowAcpiTemp=1 # 0/1
        CPUStatusShowCpuFreq=1 # 0/1
        TaskBarShowMEMStatus=1 # 0/1
        TaskBarShowNetStatus=1 # 0/1
        TaskBarShowCollapseButton=0 # 0/1
        TaskBarDoubleHeight=0 # 0/1
        ShowProgramsMenu=0 # 0/1
        ShowSettingsMenu=1 # 0/1
        ShowFocusModeMenu=1 # 0/1
        ShowThemesMenu=1 # 0/1
        ShowLogoutMenu=1 # 0/1
        ShowHelp=0 # 0/1
        ShowLogoutSubMenu=1 # 0/1
        ShowRun=1 # 0/1
        ShowWindowList=0 # 0/1
        ConfirmLogout=0 # 0/1
        ClickMotionDistance=32 # [0-32]
        ClickMotionDelay=2000 # [0-2000]
        IconPath="/usr/share/icons:/usr/share/pixmaps/papirus:/usr/share/icons/papirus-antix/48x48/apps:/usr/share/icons/papirus-antix/48x48/mimetypes"
        MailCommand="claws-mail"
        LockCommand="xlock"
        ClockCommand="yad --calendar --mouse --close-on-unfocus --undecorated --skip-taskbar --button=gtk-ok:1"
        RunCommand="gexec"
        OpenCommand="" # menu file browser - eg. spacefm or rox or desktop-defaults-run -fm
        TerminalCommand="x-terminal-emulator"
        LogoutCommand="desktop-session-exit"
        ShutdownCommand="sudo halt"
        RebootCommand="sudo reboot"
        CPUStatusCommand="lxtask"
        NetStatusCommand="cmst"
        NetworkStatusDevice="[wp]*"
        TimeFormat="%r" #US format?
        DateFormat="%c"
        KeyWinMaximizeVert="Alt+Ctrl+Up"
        KeyWinArrangeN="Alt+Ctrl+KP_Up" # Up-Move window Top 
        KeyWinArrangeNE="Alt+Ctrl+KP_Prior" # PgUp-Move window Top Right 
        KeyWinArrangeE="Alt+Ctrl+KP_Right" # Right-Move window to Right 
        KeyWinArrangeSE="Alt+Ctrl+KP_Next" # PgDn-Move window to Bottom Right 
        KeyWinArrangeS="Alt+Ctrl+KP_Down" # Down-Move window to Bottom 
        KeyWinArrangeSW="Alt+Ctrl+KP_End" # End-Move window to Bottom Left 
        KeyWinArrangeW="Alt+Ctrl+KP_Left" # Left-Move window to Left 
        KeyWinArrangeNW="Alt+Ctrl+KP_Home" # Home-Move window to Top Left 
        KeyWinArrangeC="Alt+Ctrl+KP_Begin" # 5-Center window
        KeySysSwitchNext="Alt+Tab"
        KeySysSwitchLast="Alt+Shift+Tab"
        KeySysWinNext="Alt+Esc"
        KeySysWinPrev="Alt+Shift+Esc"
        KeySysWinMenu="Shift+Esc"
        KeySysDialog="Alt+Ctrl+Del"
        KeySysMenu="Ctrl+Esc"
        KeySysWindowList="Alt+Ctrl+Esc"
        KeySysAddressBar="Alt+Ctrl+Space"
        KeySysWorkspacePrev="Alt+Ctrl+Left"
        KeySysWorkspaceNext="Alt+Ctrl+Right"
        KeySysWorkspaceLast="Alt+Ctrl+Down"
        KeySysWorkspacePrevTakeWin="Alt+Ctrl+Shift+Left"
        KeySysWorkspaceNextTakeWin="Alt+Ctrl+Shift+Right"
        KeySysWorkspaceLastTakeWin="Alt+Ctrl+Shift+Down"
        KeySysWorkspace1="Alt+1"
        KeySysWorkspace2="Alt+2"
        KeySysWorkspace3="Alt+3"
        KeySysWorkspace4="Alt+4"
        KeySysWorkspace1TakeWin="Alt+Ctrl+Shift+1"
        KeySysWorkspace2TakeWin="Alt+Ctrl+Shift+2"
        KeySysWorkspace3TakeWin="Alt+Ctrl+Shift+3"
        KeySysWorkspace4TakeWin="Alt+Ctrl+Shift+4"
        KeySysTileVertical="Alt+Shift+F2"
        KeySysTileHorizontal="Alt+Shift+F3"
        KeySysCascade="Alt+Shift+F4"
        KeySysArrange="Alt+Shift+F5"
        KeySysArrangeIcons="Alt+Shift+F8"
        KeySysMinimizeAll="Alt+Shift+F9"
        KeySysHideAll="Alt+Shift+F11"
        KeySysUndoArrange="Alt+Shift+F7"
        KeySysShowDesktop="Alt+Ctrl+d"
        KeySysCollapseTaskBar="Alt+Ctrl+h"
        WorkspaceNames=" Web ", " Mail ", " Term ", " Edit "
        TaskBarClockLeds=0 # 0/1
        TitleBarHeight=32 # [0-128]
        ScrollBarX=18 # [0-64]
        DesktopBackgroundCenter=0 # 0/1
        SupportSemitransparency=1 # 0/1
        DesktopBackgroundScaled=1 # 0/1
        DesktopBackgroundImage=""
        DesktopBackgroundColor=""

        --
        Brian Masinick

        #100449
        Member
        PPC
          Helpful
          Up
          0
          ::

          Very simple example of the GUI, that just manages the System resources system tray square, toggling it on/off:

          #!/usr/bin/env bash
          #Script to manage some IceWM toolbar settings
          #Script variables
          file=$HOME/.icewm/prefoverride
          #Make sure the prefoverride file exists:
          touch $file
          toggle_system_info_square_on_system_tray()
          {
          ###Manage the System Info toolbar square that shows information about CPU/RAM/SWAP usage:
          ###first make sure that it exists in prefoverride, then make sure it's set to 0
          text="TaskBarShowCPUStatus="
          #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
          if cat $file | grep ^$text; then
             # echo found, making sure its not commented out
              sed -i "/$text/s/^#//g" $file
          else
             # echo not found
              echo ${text}1 >> $file
          fi
          #Toggle TaskBarShowCPUStatus (if it exists in prefoverride):
          if grep -Fx  "${text}"1 "$file"; then
              sed -i "s/${text}.*/${text}0/" $file
          elif grep -Fx  "${text}"0 "$file"; then
              sed -i "s/${text}.*/${text}1/" $file
           fi
          #restart icewm, to see the change:
           icewm -r
          #Exit function:
          return
          }
          #Export created functions, so they can be used in the GUI:
          export -f toggle_system_info_square_on_system_tray
          DADOS=$(yad --length=200 --width=475 --center --title=$"Very Basic IceWM Manager" --text=$"Please select your option:" --button=$"Toggle System tray Square that displays CPU RAM SWAP":1)
          ### wait for a button to be pressed then perform the selected function
          foo=$?
          [[ $foo -eq 1 ]] && toggle_system_info_square_on_system_tray
          #100451
          Member
          PPC
            Helpful
            Up
            0
            ::

            The same basic script, now managing the 3 main “squares” that display system info on IceWM’s toolbar. It’s ugly, still very basic, but effective:

            #!/usr/bin/env bash
            #Script to manage some IceWM toolbar settings
            #Script variables
            file=$HOME/.icewm/prefoverride
            #Make sure the prefoverride file exists:
            touch $file
            toogle_system_info_square_on_system_tray()
            {
            ###Manage the System Info toolbar square that shows information about CPU/RAM/SWAP usage:
            ###first make sure that it exists in prefoverride, then make sure it's set to 0
            text="TaskBarShowCPUStatus="
            #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
            if cat $file | grep ^$text; then
               # echo found, making sure its not commented out
                sed -i "/$text/s/^#//g" $file
            else
               # echo not found
                echo ${text}1 >> $file
            fi
            #Toggle TaskBarShowCPUStatus (if it exists in prefoverride):
            if grep -F  "${text}"1 "$file"; then
                sed -i "s/${text}.*/${text}0/" $file
            elif grep -F  "${text}"0 "$file"; then
                sed -i "s/${text}.*/${text}1/" $file
             fi
            #restart icewm, to see the change:
             icewm -r
            #Exit function:
            return
            }
            toogle_RAM_info_square_on_system_tray()
            {
            ###Manage the System Info toolbar square that shows information about CPU/RAM/SWAP usage:
            ###first make sure that it exists in prefoverride, then make sure it's set to 0
            text="TaskBarShowMEMStatus="
            #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
            if cat $file | grep ^$text; then
               # echo found, making sure its not commented out
                sed -i "/$text/s/^#//g" $file
            else
               # echo not found
                echo ${text}1 >> $file
            fi
            #Toggle TaskBarShowMEMStatus:
            if grep -F  "${text}"1 "$file"; then
                sed -i "s/${text}.*/${text}0/" $file
            elif grep -F  "${text}"0 "$file"; then
                sed -i "s/${text}.*/${text}1/" $file
             fi
            #restart icewm, to see the change:
             icewm -r
            #Exit function:
            return
            }
            toogle_Network_info_square_on_system_tray()
            {
            ###Manage the System Info toolbar square that shows information about NETWORK usage:
            ###first make sure that it exists in prefoverride, then make sure it's set to 0
            text="TaskBarShowNetStatus="
            #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
            if cat $file | grep ^$text; then
               # echo found, making sure its not commented out
                sed -i "/$text/s/^#//g" $file
            else
               # echo not found
                echo ${text}1 >> $file
            fi
            #Toggle TaskBarShowMEMStatus:
            if grep -F  "${text}"1 "$file"; then
                sed -i "s/${text}.*/${text}0/" $file
            elif grep -F  "${text}"0 "$file"; then
                sed -i "s/${text}.*/${text}1/" $file
             fi
            #restart icewm, to see the change:
             icewm -r
            #Exit function:
            return
            }
            #Export created functions, so they can be used in the GUI:
            export -f toogle_system_info_square_on_system_tray toogle_RAM_info_square_on_system_tray toogle_Network_info_square_on_system_tray
            DADOS=$(yad --length=200 --width=475 --center --title=$"Very Basic IceWM Manager" --text=$"Please select your option:" --button=$"Toggle CPU RAM SWAP info":1  --button=$"Toggle RAM info":2 --button=$"Toggle Network info":3)
            ### wait for a button to be pressed then perform the selected function
            foo=$?
            [[ $foo -eq 1 ]] && toogle_system_info_square_on_system_tray
            [[ $foo -eq 2 ]] && toogle_RAM_info_square_on_system_tray
            [[ $foo -eq 3 ]] && toogle_Network_info_square_on_system_tray

            As you can see, for each option that has only 1/0 value, all the script does is, for each function, to change the contents of the “text” variable, to match the string whose value has to be swapped from 1 to 0 or 0 to 1.
            It’s only a matter of adding new functions related to what variable we want to toggle. So, I’ll add “auto-hide”, “position toolbar on top” and “double height toolbar” that way. To edit Workspace’s, I’ll simply call Robin’s “workspace manager” script. Clock settings will be harder to change, has will “toogle on/off names of windows on the taskbar” option- because, well, that does not exist, it’s a fiction, implemented by using a certain size in a variable, but I’m optimist about making a usable GUI for Managing, at least some IceWM settings…

            P.

            • This reply was modified 9 months, 1 week ago by PPC.
            #100465
            Member
            PPC
              Helpful
              Up
              0
              ::

              For today, it’s all I can do:
              The script now toggles on and off the squares about CPU/RAM; RAM; Network. It toggles between 12h/24h clock and toggles seconds on the clock on/off – that’s, for me, the most important changes (and I think, what most people want to change, if any, from the default toolbar settings).

              Important TO DO’s:
              – add toggle auto-hide toolbar on/off (easy to implement)
              – add toggle toolbar at top/bottom (easy to implement)
              – add toggle normal toolbar/ double height toolbar (easy to implement)
              – use LED clock (easy to implement)
              – toggle clock on/off (easy to implement)
              – toggle Show app’s icon on it’s window’s title bar (easy to implement)
              – Center large windows (easy to implement)
              – toggle ShowMoveSizeStatus (easy to implement)
              – toggle “Show desktop icon” on/off ???
              – toggle Titles of windows on the taskbar on/off (hard to implement)
              – link to Robin’s Workspace script (no idea how to implement that one)
              – A better User Interface (???)

              The current version script:

              #!/usr/bin/env bash
              #Script to manage some IceWM toolbar settings
              #Script variables
              file=$HOME/.icewm/prefoverride
              #Make sure the prefoverride file exists:
              touch $file
              toogle_system_info_square_on_system_tray()
              {
              ###Manage the System Info toolbar square that shows information about CPU/RAM/SWAP usage:
              ###first make sure that it exists in prefoverride, then make sure it's set to 0
              text="TaskBarShowCPUStatus="
              #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
              if cat $file | grep ^$text; then
                 # echo found, making sure its not commented out
                  sed -i "/$text/s/^#//g" $file
              else
                 # echo not found
                  echo ${text}1 >> $file
              fi
              #Toggle TaskBarShowCPUStatus (if it exists in prefoverride):
              if grep -F  "${text}"1 "$file"; then
                  sed -i "s/${text}.*/${text}0/" $file
              elif grep -F  "${text}"0 "$file"; then
                  sed -i "s/${text}.*/${text}1/" $file
               fi
              #restart icewm, to see the change:
               icewm -r
              #Exit function:
              return
              }
              toogle_RAM_info_square_on_system_tray()
              {
              ###Manage the System Info toolbar square that shows information about CPU/RAM/SWAP usage:
              ###first make sure that it exists in prefoverride, then make sure it's set to 0
              text="TaskBarShowMEMStatus="
              #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
              if cat $file | grep ^$text; then
                 # echo found, making sure its not commented out
                  sed -i "/$text/s/^#//g" $file
              else
                 # echo not found
                  echo ${text}1 >> $file
              fi
              #Toggle TaskBarShowMEMStatus:
              if grep -F  "${text}"1 "$file"; then
                  sed -i "s/${text}.*/${text}0/" $file
              elif grep -F  "${text}"0 "$file"; then
                  sed -i "s/${text}.*/${text}1/" $file
               fi
              #restart icewm, to see the change:
               icewm -r
              #Exit function:
              return
              }
              toogle_Network_info_square_on_system_tray()
              {
              ###Manage the System Info toolbar square that shows information about NETWORK usage:
              ###first make sure that it exists in prefoverride, then make sure it's set to 0
              text="TaskBarShowNetStatus="
              #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
              if cat $file | grep ^$text; then
                 # echo found, making sure its not commented out
                  sed -i "/$text/s/^#//g" $file
              else
                 # echo not found
                  echo ${text}1 >> $file
              fi
              #Toggle TaskBarShowMEMStatus:
              if grep -F  "${text}"1 "$file"; then
                  sed -i "s/${text}.*/${text}0/" $file
              elif grep -F  "${text}"0 "$file"; then
                  sed -i "s/${text}.*/${text}1/" $file
               fi
              #restart icewm, to see the change:
               icewm -r
              #Exit function:
              return
              }
              toggle_seconds()
              {
              Show/hide seconds on clock
              text="TimeFormat="
              #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
              if cat $file | grep ^$text; then
                 # echo found, making sure its not commented out
                  sed -i "/$text/s/^#//g" $file
              else
                 # echo not found, use default values
                  echo ${text}%H:%M:%S  >> $file
              fi
              #Toggle value:
              if grep -F  ":%S" "$file"; then
                  sed -i "s/\:%S.*/ /" $file
              else
                  sed -i "s/\:%M.*/:%M:%S/" $file
               fi
               
              #restart icewm, to see the change:
               icewm -r
              }
              toggle_12h_24h()
              {
              Show/hide seconds on clock
              text="TimeFormat="
              #Check if string exists in  file, if it does not, add it and make sure it's set to 0 (its 1 be default):
              if cat $file | grep ^$text; then
                 # echo found, making sure its not commented out
                  sed -i "/$text/s/^#//g" $file
              else
                 # echo not found, use default values
                  echo ${text}%H:%M:%S  >> $file
              fi
              #Toggle value:
              if grep -F  "%H" "$file"; then
              	sed -i 's/%H/%l/' $file
                 else
                  sed -i 's/%l/%H/' $file
               fi
               
              #restart icewm, to see the change:
               icewm -r
              }
              #Export created functions, so they can be used in the GUI:
              export -f toogle_system_info_square_on_system_tray toogle_RAM_info_square_on_system_tray toogle_Network_info_square_on_system_tray toggle_seconds toggle_12h_24h
              DADOS=$(yad --length=200 --width=475 --center --title=$"Very Basic IceWM Manager" --text=$"Please select your option:" --button=$"Toggle CPU RAM SWAP info":1  --button=$"Toggle RAM info":2 --button=$"Toggle Network info":3 --button=$"Toggle Seconds in clock":4 --button=$"Toggle 12h/24h clock":5)
              ### wait for a button to be pressed then perform the selected function
              foo=$?
              [[ $foo -eq 1 ]] && toogle_system_info_square_on_system_tray
              [[ $foo -eq 2 ]] && toogle_RAM_info_square_on_system_tray
              [[ $foo -eq 3 ]] && toogle_Network_info_square_on_system_tray
              [[ $foo -eq 4 ]] && toggle_seconds
              [[ $foo -eq 5 ]] && toggle_12h_24h
              #100473
              Member
              PPC
                Helpful
                Up
                0
                ::

                If took less time than I though it would, implementing the changes and testing them. This beta version of the script should work fine.
                Please test, if possible.

                It manages what I think are the most common settings anyone would want to change on the toolbar, and window management.
                I opted not to include, in the script, an option to include the tiling windows+arrow keys options. I think this option should be on be default on future antiX versions.
                I think that, although still not pretty, this GUI is still a great improvement over the default way of managing IceWM, making it more usable even for completly non tech savvy users.
                I’ll bet some people will find out at least on option they had no idea existed in IceWM, on this script.

                As always, feedback is appreciated.

                P.

                #100479
                Member
                blur13
                  Helpful
                  Up
                  0
                  ::

                  #TitleBarHeight=0
                  # Horizontal window border
                  #BorderSizeX=0 # [0-128]

                  # Vertical window border
                  #BorderSizeY=0 # [0-128]

                  I have these in my prefoverride file, its useful to maximize “screen real estate” when working on a small screen with tiling windows.

                  icesh -f if -P _NET_FRAME_EXTENTS=0 then bordered else borderless

                  The above is a useful one-liner to toggle “decorations” on and off, can be configured to a keyboard shortcut.

                  PPC, you might want to look into icesh, its quite useful for “conditionals” and it has immediate effect, no need to restart icewm.

                  • This reply was modified 9 months, 1 week ago by blur13.
                  #100484
                  Moderator
                  Brian Masinick
                    Helpful
                    Up
                    0
                    ::

                    I changed this to
                    TimeFormat=%r
                    in prefoverride
                    I actually have
                    TimeFormat="%r"
                    in my preferences file already, but I changed it in prefoverride rather than remove the file, at least while testing the script.
                    The things I tested worked fine other than my personal preferred value, which I changed.

                    --
                    Brian Masinick

                    #100532
                    Member
                    PPC
                      Helpful
                      Up
                      0
                      ::

                      I was able to edit the name of this thread, since we now have a fully working GUI to manage most of the essential settings.
                      The new version canabalizes Robin’s excelent script to manage workspaces (allowing to easily add/remore/rename workspaces), and also BobC’s et all script to memorize the position of Windows.
                      I also included buttons to access Toolbar Icon Manager and Personal Menu Manager.

                      As it stands, the GUI (and summoned scripts) mostly avoids that regular users have to edit the “personal”, “toolbar”, “preferences”/”prevoverride” and “winoptions” config files.
                      I would like to have back the script that manages the “startup” file, so no one that does not want to, has no need to manually edit IceWM’s config files.

                      Note1: I do think that the “menu” file should be edited manually – too much can go wrong if we try to automatize editing it. The most I think the GUI should do is asking if the Personal entries should be on a Sub-menu or displayed directly in the first layer of the menu. Also, maybe a toggle to show/hide the “Recent files” submenu, but that’s all.

                      Note2: If this script ever gets included in antiX, then the icewm-remember and robin’s workspace-manager scripts should be included too (hell, they should be included in antiX even if this GUI isn’t, they are that good). As things are now, they are included in the same zip file as the script and the script expects them to be on the same folder as the GUI script, so uncompress them all to the same folder!!!

                      I do think that this 3 scripts (and the Toolbar Icon Manager and Personal menu editor, now available from this GUI), plus one to manage the startup file do add a degree of ease of customization to antiX/IceWM that it needed, without costing maybe no more than than 100kb or so of disk space.
                      As is, this version of the script is completely usable.

                      P.

                      • This reply was modified 9 months, 1 week ago by PPC.
                      #100546
                      Member
                      blur13
                        Helpful
                        Up
                        0
                        ::

                        This is pretty cool. I remember when I first started using icewm that I found the 1430 lines in the preferences file quite daunting. It was also very confusing that changing some options had no effect. I learned later that those options were controlled by the theme and had to be placed in the (non-existent) prefoverride file.

                        Good job!

                        #100547
                        Moderator
                        Brian Masinick
                          Helpful
                          Up
                          0
                          ::

                          @PPC: regardless of what happens and where your scripts end up, they have been a very worthwhile exercise.

                          I hope at the very least they become a package in our repository. I believe that some of the scripts made it into the antix-goodies package already, so that is encouraging.

                          One other thing worth considering is to send your tools to the IceWM project team.
                          Perhaps they would consider either including them into their window manager or providing them as an additional management accessory. They are certainly well worth considering!

                          No matter what happens from here I appreciate and applaud everything you are doing to preserve efficiency while also improving setup and configuration!

                          --
                          Brian Masinick

                          #100553
                          Member
                          Xunzi_23
                            Helpful
                            Up
                            0
                            ::

                            Thanks PPC, Robin, BobC.
                            Agree with blur 13, ICEWM has a sometimes steep learning curve.

                            Will include the scripts on my master setup for new users and
                            hope they will be easily available from package manager or even
                            delivered with antiX sometime in the future.

                            See how new user Welshman gets along with all the possibilitys
                            next week :-).

                            #100568
                            Member
                            PPC
                              Helpful
                              Up
                              0
                              ::

                              Many thanks, everyone. Even if anticapitalista does not include this script in antiX, at least we have a resource to point to users that want to easily edit how IceWM behaves.
                              Just for the sake of completion, I’m thinking of adding buttons to lxappearance and to wallpaper script. Unfortunatly, I think that adding a GUI to select the theme would just be too hard, and that can already be easily done from the menu (unlike most other tasks the GUI does).

                              Partly off topic, but related to GUI’s to help manage antiX:

                              @Brian Masinick – yes, fortunatly, anticapitalista accepted some scripts that I created, over the years, that are now part of antiX: the GUI to set the time/date was created by me and Skidoo; IceWM’s Toolbar Icon Manager; Android Connect (with Sybok’s help, he taught me a lot about about structuring scripts, shame I’m not that well organized); antiX Updater (that, for some random reason, led to me being personally attacked here in the forum); Personal Menu Manager; yad-calendar was suggested by me (the GUI calendar that appears when users click the clock, before that was a cli calendar), yad-volume (available, but without a desktop file- it’s meant to be used as a toolbar entry, to replace having volumeicon always running, saving RAM on low powered devices). I hope that the GUI to enable/disable UFW also gets to be included in antiX. FT10-transformation is a package available in the antiX repository (Xecure helped a lot, creating it). FT10 include some small scripts that I think are useful, so in a way most of my scripts are either included in antiX full, out of the box or available inside FT10.

                              P.

                              • This reply was modified 9 months, 1 week ago by PPC.
                              • This reply was modified 9 months, 1 week ago by PPC.
                              #100569
                              Moderator
                              Brian Masinick
                                Helpful
                                Up
                                0
                                ::

                                I understand both views on convenience tools. For the novice, they can be extremely helpful; for the veteran they can be handy, but are not mandatory. For the minimalist they are a distraction and overhead. Given this, I hope that what we have by default is the inclusion of these efforts as packages in our repository.

                                I’d be happy if someone who enjoys packaging and building systems would create a full featured, simple variation of antiX that DOES include your tools as the default environment.
                                While this may not be something for all, your tools are still pretty efficient and such a variation would provide an excellent entry point for those who are completely new to Linux or antiX. On the other hand, I definitely want to see ultra efficient base and full versions as always.

                                --
                                Brian Masinick

                                #100573
                                Forum Admin
                                anticapitalista
                                  Helpful
                                  Up
                                  0
                                  ::

                                  This is what I’m planning.

                                  Putting all IceWM scrits into a package called icewm-goodies (obviously removing any already in antix-goodies).
                                  Removing yad-* scripts from antix-goodies > yad-goodies deb
                                  All scripts with a .desktop file to be either standalone apps or part of a new gui-goodies deb. I’m leaning towards the first.
                                  antix-goodies to be scripts without a .desktop file so they will not appear in the menu.

                                  Philosophers have interpreted the world in many ways; the point is to change it.

                                  antiX with runit - leaner and meaner.

                                Viewing 15 posts - 1 through 15 (of 123 total)
                                • You must be logged in to reply to this topic.