antiX-23 – based on Debian 12 Bookworm – ideas

Forum Forums antiX-development Development antiX-23 – based on Debian 12 Bookworm – ideas

  • This topic has 201 replies, 27 voices, and was last updated May 11-9:17 pm by Robin.
Viewing 15 posts - 106 through 120 (of 202 total)
  • Author
    Posts
  • #98167
    Member
    PPC
      Helpful
      Up
      0
      ::

      @anticapitalista :
      Sucess in having a context menu entry that only shows up if the user is in the Trash folder, that allows to restore the file to it’s original folder.
      In case a file already exists with the same name, a number will be appended to the end of the restored file (yes, changing it’s extension! ex: .docx -> .docx~1~)

      Please adapt this, to your zzzfm config file and test (you’ll have to edit the cstm_0783b17b-next=~field. Also the “label” is “Restore file” and it ideally be localized. Also, a nice icon (something like an arrow leaving the Trash Can would be nice)…

      cstm_0783b17b-label=Restore
      cstm_0783b17b-next=cstm_25a291d5
      cstm_0783b17b-cxt=0%%%%%2%%%%%2%%%%%3%%%%%.local/share/Trash/files
      cstm_0783b17b-prev=edit_delete
      cstm_0783b17b-line=selection0=%f\nselection=$(basename $selection0)\nextension=".trashinfo"\norigin_of_selected_file0=$HOME/.local/share/Trash/files/$selection\ndata_about_selected_file0=$HOME/.local/share/Trash/info/$selection$extension\noriginal_path_of_file=$(cat $data_about_selected_file0 | grep "Path=" |cut -c6-)\nmv --backup=numbered $selection0 $original_path_of_file\nrm $data_about_selected_file0\n
      cstm_0783b17b-task=1
      cstm_0783b17b-task_err=1
      cstm_0783b17b-task_out=1
      cstm_0783b17b-keep=1

      Edit:
      In case you want to try to manually add this entry:
      – Open zzzfm and navigate to any folder with files (ex: ~)
      – Right click a file, to access the contextual menu
      – Right click over the “Delete” menu entry and select “+ New” > “Command”
      – Name the entry something like “Restore file”/”Undelete file”/etc
      – On the Command tab enter this code:

      selection0=%f
      selection=$(basename $selection0)
      extension=".trashinfo"
      origin_of_selected_file0=$HOME/.local/share/Trash/files/$selection
      data_about_selected_file0=$HOME/.local/share/Trash/info/$selection$extension
      original_path_of_file=$(cat $data_about_selected_file0 | grep "Path=" |cut -c6-)
      mv --backup=numbered $selection0 $original_path_of_file
      rm $data_about_selected_file0

      -On the Context tab select this (sorry, if not accurate, I’m using zzzfm in pt) (also note: this is part is not very intuitive, but make sure that you end up with this result):
      “Show” item if context “does not match any of the following rules”
      “Folder/Directory” “does not contain” “.local/share/Trash/files”

      -Click “Ok” on the bottom right

      -Now the “Restore” contextual menu should only come up if you are in the Trash folder. It allows you the restore the selected file, or the first of several selected files

      NOTE: this only works to restore 1 file at a time!!!! It would be more complex, making it work with several selected files – anyone better than me at bash scripting, please, take a stab at it!

      Edit: in a following post is the “script” that allows users to restore several files at once.

      P.

      • This reply was modified 3 months, 2 weeks ago by PPC.
      • This reply was modified 3 months, 2 weeks ago by PPC.
      • This reply was modified 3 months, 2 weeks ago by PPC.
      #98171
      Forum Admin
      anticapitalista
        Helpful
        Up
        0
        ::

        @PPC – I did the manual way and it worked. Great!

        However, I noticed that the bookmarks folders only work on live since it expects to see a demo user.

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

        antiX with runit - leaner and meaner.

        #98172
        Member
        PPC
          Helpful
          Up
          0
          ::

          @anticapitalista:

          To solve the problem with the bookmarks only working in “demo” user, try this:
          – make sure zzzfm is closed
          – edit it’s session file, replacing all instances of “/home/demo” with “~” this *should* work

          New version of the mini script to restore files from zzzfm’s contextual menu, that allows to select and restore as many files as the user wants:

          for file in %F; do
          selection0=$file
          selection=$(basename "$selection0")
          extension=".trashinfo"
          origin_of_selected_file0=$HOME/.local/share/Trash/files/$selection
          data_about_selected_file0=$HOME/.local/share/Trash/info/$selection$extension
          original_path_of_file=$(cat "$data_about_selected_file0" | grep "Path=" |cut -c6-)
          mv --backup=numbered "$selection0" "$original_path_of_file"
          rm "$data_about_selected_file0"
          done

          I tested this “script” many times in many ways. The only “bug” is that if the original file has spaces in it’s name, they are replaced with strange characters (like it happened in the recent files list, in icewm’s menu). In time, I’ll try to find a way around that. Other than this problem, I think the script is perfect- it restores files, it works with several files, it (kinda) works with files with spaces, the entry only shows up when it’s expected…

          ZZZfm is very powerful, it’s a shame it’s so hard to configure! But once configured, it’s very nearly the perfect File Manager.

          Edit:
          1- I just tested the solution to the user problem and it seems to work – if using ~ in the config file, zzzfm respects it and goes to the user’s home.
          2- I took a look – the problem restoring files with spaces in their names is due to the way trash-cli stores the data about the original name and place of the file (that uses %xx to replace spaces or special characters). with time, I can adjust the “restore files” script to use the same solution I suggested for the “recent files” script – but I’m can’t do it right now…

          P.

          • This reply was modified 3 months, 2 weeks ago by PPC.
          #98176
          Member
          PPC
            Helpful
            Up
            0
            ::

            @anticapitalista – I just realized that a new “command” can be used to “manually” mount listed partitions, on zzzfm, by right clicking a partition and adding a new command called something like “Mount external partition”, with this contents:

            gksu "mount %v /mnt"

            Obviously, a similar entry to “Unmount external partition” can be added:

            gksu "umount %v" zzzfm /mnt

            But this does go against the safe guard of now allowing to use a GUI to mount external partitions…

            P.

            • This reply was modified 3 months, 2 weeks ago by PPC.
            #98180
            Member
            PPC
              Helpful
              Up
              0
              ::

              @anticapitalista – brain hurts, please send aspirin…

              Solution to the problem of restoring files with spaces or special characters, using a zzzfm contextual menu:

              for file in %F; do
              file_name=$(basename "$file")
              extension=".trashinfo"
              data_about_selected_file=$HOME/.local/share/Trash/info/$file_name$extension
              original_path_of_file=$(cat "$data_about_selected_file" | grep "Path=" |cut -c6-)
              original_file_path=$(dirname "$original_path_of_file")
              mv --backup=numbered "$file" "$original_file_path/$file_name"
              rm "$data_about_selected_file"
              done

              Please test, should work fine…

              Edit: Also, I think I understood how “mv –backup” works wrong. I tested: if there is a file with the same name of the file being moved to the folder, the older file, existing on that folder will be backed up and renamed, appending ~1~ to it’s end.
              Edit2: I replaced the code above with a simpler, and more human readable one. I hope that can help possible future “plugins” for zzzfm (like converting image files, etc).

              P.

              • This reply was modified 3 months, 2 weeks ago by PPC.
              • This reply was modified 3 months, 2 weeks ago by PPC.
              • This reply was modified 3 months, 2 weeks ago by PPC.
              #98200
              Member
              Xunzi_23
                Helpful
                Up
                0
                ::

                Two small suggestions.

                A small gui application to set default papersize in /etc and preferably also create a
                papersize file in home or prompt user to copy the newly created file in to his home
                directory. Unfortunately not all applications look in /etc.

                Getting a4 or other than us size set up without help is a huge obstacle for a new user.

                In live remaster set Personal as default, new user is losing changes and wondering
                why for distribution is standard.
                I ran in to same problem a few times too before becoming more careful.

                Change is easily made, done for personal and friends use already.

                #98707
                Member
                PPC
                  Helpful
                  Up
                  0
                  ::

                  So, I return with some new suggestions and what I think the next version of antiX likely to include:

                  What I think is probably in antiX future:
                  – A slightly cleaner menu, with a clear way to search for apps in the menu, a default toolbar with a clear way to update the system and also add/remove quicklauncher to itself (already available in the currently available config files)
                  – An updater that does not have to keep asking users questions – because that can be annoying and yes, scary to new users, because they are simply not used to being in control on every single thing their computer does. Most people do not want control, they want to click a “thingie” and have the computer do it’s magic… My current antiX updater script already presents users with that choice [ ironic, I know]- to have an automated upgrade process – they usually do not have to make any selection, the script will always choose the default option (and no, it’s not always “yes”)
                  – ZZZfm with some addictions – like the default Bookmarks, and Trash Can, hopefully, it’s the default File Manager

                  This alone with make antiX much more usable even by non techies, that are not afraid to try something slightly different- hell, if you know your way around any Windows up to Windows 7, you can handle antiX for normal stuff, like browsing the web, using your e-mail, working with documents, managing your files, etc…

                  Some suggestions, that I think would be nice in Package Installer:
                  – For Gamming: Lutris, Heroic (game launcher for Epic Games) – having these options would make almost every single commercial game that is available under Linux, available in antiX.
                  Adding some more FOSS games, I can suggest a few, if needed
                  – For Office work: OnlyOffice (available, I think, only for 64bits- https://download.onlyoffice.com/install/desktop/editors/linux/onlyoffice-desktopeditors_amd64.deb but I do not knoe if it can be compiled for 32bits) and yes, even old OpenOffice – with a warning that it uninstalls LibreOffice- because I tested on my netbook and Laptop and OpenOffice runs laps around LO, on extremely slow machines, once it’s up and running (mainly because it still has the option to have a quickstarter in the system tray, that makes it launch any of it’s apps almost instantly, even on a patato computer). add also an entry, something like “Annotate and rearrange PDF’s with Xournal++”. It’s relatively easy to use, and powerful, if all that users want to do is highlight text they are studying in a pdf document, or write small notes on it. NOTE: that can currently be done in almost any modern web browser, I know…
                  -If possible, package (a lot of work, I assume), and include in P.I. the endless list of browsers for older computers, available here in the forum- they can make old 32bits pc’s usable in the web, once again.
                  -Flatpak support would be great- by this I mean, the option to install and configure flatpak on antiX, and not having flatpaks available to install from PI (like MX has, although I like that idea, I assume it does not fit the Dev Team view of what this OS should be).
                  -Without false modesty – FT10 Transformation Pack should be there – users that need it the most should have an easy way to install it- if adding it, in it’s description, it should state how to enable it (antix Menu > Applications > Preferences …)

                  On the Control Panel, a more evolved version of the script I suggested to set the default paper size would be nice- I had no easy solution to achieve that, in my new antiX 22…

                  As always, I keep my suggestion of using Skidoo’s version of Package Installer – that makes it a one shop stop to install anything on the debian repository, not just our great (but also little) list of curated apps. It just makes sense, having a “store” that allows users to install (or uninstall) ANYTHING (well, at least the packages in the repository).

                  EDIT: for people that use antiX for office work, and need a working Scanner– having SANE available from the Package installer would make life simpler [I just realized that P.I. did not provide a way to make my scanner work with antiX- I may be wrong, but I thought that, in antiX 19 I did not have to install hplip, to use my scanner, but I had to do that in antiX 22 runit full, 64bits- I did so first installing SANE using apt (the scanner was not detected) and then the HP stuff I don’t recall needing, from the the Control Center).

                  EDIT2: Like Marcelo says, also, some console emulators, would be nice, for gamers – like RetroArch and Mame, I suggest also SCUMM (point and click adventure game emulator), for adventure games – there are half a dozen or so of very nice free games available for SCUMM. And there’s probably some users with dusty old CD’s of very playable adventure games they can bring back to life.

                  P.

                  • This reply was modified 3 months, 1 week ago by PPC.
                  • This reply was modified 3 months, 1 week ago by PPC.
                  • This reply was modified 3 months, 1 week ago by PPC.
                  #99743
                  Member
                  Robin
                    Helpful
                    Up
                    1
                    ::

                    Updated script version of proposal for antiX desktop count switcher, this time based on gtkdialog instead of yad, to avoid some shortcomings:

                    (original script proposal)

                    #!/bin/bash
                    # -*- coding: utf-8 -*-
                    # GPL v.3
                    # antiX desktop count switcher
                    # by antiX community 2023
                    # ver. 0.2
                    
                    TEXTDOMAINDIR=/usr/share/locale 
                    TEXTDOMAIN=antiX-workspace-count
                    
                    GtkdlgRahmen=false
                    #symbol_antiX=antixlogo  # GTK named symbol needed here
                    symbol_antiX="preferences-desktop-theme"
                    initial=$(wmctrl -d | wc -l)
                    dx=$(wmctrl -d | grep "*" | cut -d" " -f5 | cut -dx -f1)
                    dy=$(wmctrl -d | grep "*" | cut -d" " -f5 | cut -dx -f2)
                    
                    export ANTIX_DESKTOP_COUNT_DIALOG='
                    <window title="'$"aWCS antiX workspace count switcher"'" decorated="$GtkdlgRahmen" icon-name="'$symbol_antiX'" skip_taskbar_hint="true" resizable="false">
                      <vbox>
                        <text use-markup="true">
                          <label>"<b>'$"antiX workspace count switcher"'</b>"</label>
                        </text>
                        <hbox>
                          <text>
                            <label>'$"Set the desired number of desktops:"'</label>
                          </text>
                          <spinbutton range-min="1" range-max="32" range-step="1" range-value="'$initial'" tooltip-text="'$"Use mouse wheel or click on arrows. You can also enter a number by keyboard followed by enter key. The change takes place immediately."'">
                    	    <variable>ANZAHL</variable>
                    	    <action>"wmctrl -n $ANZAHL"</action>
                          </spinbutton>
                        </hbox>
                        <hbox space-expand="true" space-fill="true">
                          <text><label>""</label></text>
                          <button tooltip-text="'$"Click »Done« when desired number of workspaces was set."'">
                          <label>"'$"Done"'"</label>
                          </button>
                          <text><label>""</label></text>
                        </hbox>
                      </vbox>
                    </window>
                    '
                    
                    gtkdialog --program=ANTIX_DESKTOP_COUNT_DIALOG -G "+$(bc <<<"scale=0; $dx*0.9/10")+$(bc <<<"scale=0; $dy*8.5/10")" >/dev/null
                    
                    exit 0
                    

                    This dialog will come up right above the workspace switcher in antiX taskbar. The number of desktops will change immediately when scrolling the mouse wheel while hovering over the numeric entry field or when clicking the arrows. Also you can enter the number by keyboard and press enter.

                    If somebody could integrate an entry for this into the existing context menu list of the workspace switcher, this dialog could easily accessed by right clicking on this existing switcher field and selecting its entry from that conctext menu, right next to the place where it comes up.

                    Using this script you can fast and easily change the desktop count on the fly.

                    antiX desktop count switcher ver.0.2

                    In case there are program windows open in a removed desktop when reducing the count, these will get automatically moved to the highest remaining desktop.

                    Btw, what would be the proper English wording? I’m not sure about whether it should get called „Workspace switcher” or „Desktop switcher”. What would the native English speakers suggest?

                    Script is prepared for translation already. In the attached .zip archive you’ll find the respective .pot file along with the scriptfile itself. (Haven’t done a test translation by now, but it should work anyway.)
                    Please let me know whether any changes in English wording are needed, after this I’ll upload the resource to transifex for translation.

                    All this will be available soon on gitlab for download.

                    —-
                    P.S.: One of my main resources of knowledge about GTKdialog scripting has gone: GTKdialog Reference. At archive.org there are backup copies of the original site, but I don’t know whether this backup is complete or whether there are missing some chapters. Last June the original site was present still.

                    Windows is like a submarine. Open a window and serious problems will start.

                    #99751
                    Moderator
                    Brian Masinick
                      Helpful
                      Up
                      1
                      ::

                      Nice tool Robin. When I look at my current “Workspace”, that is the term that IceWM is using. In my case I change the Workspace numbers to some “names” that I have used for many years, and I typically use these with whatever window or desktop manager – " Web ", " Mail ", " Term ", " Edit "
                      and for me, I put those entries in the file preferences as follows –
                      WorkspaceNames=" Web ", " Mail ", " Term ", " Edit "

                      I don’t know if anyone is interested in names instead of numbers, but if you ARE, look in the file preferences for the variable WorkspaceNames.

                      I believe that by default it’s typically set to –
                      WorkspaceNames=" 1 ", " 2 "

                      It can be changed by using a similar syntax and changing the comma separated list with quoted values as indicated.

                      --
                      Brian Masinick

                      #99764
                      Moderator
                      Brian Masinick
                        Helpful
                        Up
                        1
                        ::

                        I tried out your script, Robin, with my existing setup; When I first tried it out, I had the four workspaces as I indicated in the previous note.
                        Your script correctly saw that I had 4 existing workspaces. When I set it to 5, it added a 5 on the fifth workspace. When I put it back to 4, it kept my names intact; I decreased it to 3 and it hid one of the workspaces, but then I toggled it back to 4 before exiting the script, and it didn’t mess up any of my names, so I was really happy with that, plus the tool works as advertised. I think it’s a lightweight handy addition.

                        Thanks for sharing it. I hope my comments are helpful to you and others.

                        --
                        Brian Masinick

                        #99805
                        Member
                        Robin
                          Helpful
                          Up
                          1
                          ::

                          Many thanks for checking, Brian! I’m glad to see changing the count, applying the method used in the script, honours your workspace labels.
                          Concerning lightwight: The script takes some system resources only while the dialog is opened. This count switcher doesn’t take any resources constantly afterwards.

                          Windows is like a submarine. Open a window and serious problems will start.

                          #99810
                          Member
                          Xunzi_23
                            Helpful
                            Up
                            0
                            ::

                            Hi Robin, many thanks for useful script, for clarity I would call it „Add or remove Workspaces”
                            it is a longer title but the application does not switch between workspaces, desktop switcher
                            would maybe confuse users due the availability of other desktops in antiX.

                            #99828
                            Member
                            Robin
                              Helpful
                              Up
                              0
                              ::

                              does not switch between workspaces, desktop switcher
                              would maybe confuse users

                              Exactly this was my concern while pondering about the precise English wording to be used here. Thinking in English language while writing renders script creation way more difficult to me.
                              So I found a soulution only after test translating the .pot file to my native language:

                              Window title will read: antiX Workspaces — Change number of workspaces.
                              Bold header within window: antiX Workspaces
                              Description text left of entry field: Set desired number:

                              Test translation to German language attached. As expected translation works properly when .mo file is copied to the respective system folder, so the .pot translation template file is fine.
                              Will need some developers notes to be added, so translators on transifex can easily decide how to translate the strings.

                              If the native speakers give their OK to the new English wording proposed, I’ll change the wording in script file to the above strings and then upload to transifex for translation, and make the script available on gitlab for easy handling.

                              it should be something like “WorkSpace’s Manager”.

                              A naming like that would require some additional functionallity, e.g. an additional button for accessing a dialog for changing the workspace names as proposed by Brian. Will see whether I can add something like that later. Should be not that difficult applying some sed commands to change the lines in the preferences file as described by Brian. But for now I consider the script as ready for use, when on gitlab. Would be great if seeing it integrated in antiX 23.

                              Attachments:

                              Windows is like a submarine. Open a window and serious problems will start.

                              #99833
                              Moderator
                              Brian Masinick
                                Helpful
                                Up
                                0
                                ::

                                @Robin: As before, I like your proposal for names and titles.

                                Window title will read: antiX Workspaces — Change number of workspaces.
                                Bold header within window: antiX Workspaces
                                Description text left of entry field: Set desired number:

                                As I demonstrated earlier, it would also be nice to have an optional tool to alter the convention – allow either names or numbers to describe each workspace.
                                I’ve not seen a tool previously that provides that service, but as you can see in my examples, it’s definitely possible; I’ve done that for over two decades.

                                --
                                Brian Masinick

                                #99834
                                Member
                                PPC
                                  Helpful
                                  Up
                                  0
                                  ::

                                  Would be great if seeing it integrated in antiX 23.

                                  Let me correct you on that- it would be great of this feature was integrated in IceWM it self! In my opinion, it’s main problem is that using the menu or toolbar contextual menus to edit the settings is a mess- It requires an easy GUI way to change the most basic settings.
                                  The way I’m using antiX 22 – with the default IceWM toolbar and menu (I tweaked a bit the menu, according to my previous suggestions) and having the new T.I.M. to manage the toolbar quick launchers, and a new version of it, to manage the Personal (sub-menu or, as I propose to be available to users, menu entries, on the top of the menu)… lets say antix can put most Desktop Environments to shame… It would be great if antiX 23 implements some of the suggestions made here- just to be perfectly clear – the important stugg is Robin’s WorkSpace Script and the new T.I.M. version, all the rest of my suggestions are secondary.

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