spaceFM custom dialogs

Forum Forums General Tips and Tricks spaceFM custom dialogs

  • This topic has 11 replies, 5 voices, and was last updated Jan 15-9:02 pm by sleekmason.
Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #47820
    Anonymous

      http://ignorantguru.github.io/spacefm/spacefm-manual-en.html#dialog
      https://github.com/IgnorantGuru/spacefm-plugins/wiki#ig-example-application
      https://github.com/IgnorantGuru/spacefm-plugins/blob/master/ig-example-app

      .

      .

      
      spacefm -g --label "\n 😴" --title "potato" \
         --hbox --icon dialog-password --button ok \
         --button "maybe" --button "three blind mice" \
         --label "it's\ta\tsafe\t\t" --vbox \
         --icon weather-few-clouds --vbox \
         --label "      berry pie\nclue" \
         --input  --viewer --scroll ~/.bash_history
      #47821
      Member
      ex_Koo
        Helpful
        Up
        0
        ::

        Thanks skidoo

        The plugin that I would like to install is https://github.com/IgnorantGuru/spacefm-plugins/tree/master/ig-spacetv/pkg but it just won’t install or more likely I don’t know how to install it.

        #47822
        Member
        PPC
          Helpful
          Up
          0
          ::

          Thanks skidoo

          The plugin that I would like to install is https://github.com/IgnorantGuru/spacefm-plugins/tree/master/ig-spacetv/pkg but it just won’t install or more likely I don’t know how to install it.

          I extend SpaceFM capabilities a lot – It’s extremely modular…
          Easy way to use that amazing little script:
          1- Go to https://raw.githubusercontent.com/IgnorantGuru/spacefm-plugins/master/ig-spacetv/src/cstm_325c1cf6/spacetv.sh and copy the script’s text
          2- Open a text editor (like geany), paste all the text you just copied and save it as “spacetv.sh” anywhere you want, like your home folder, for example
          3- Navigate to that script’s location and make it executable (select it, “CTRL+P”, make sure to check the “execute” box, click ok)
          4- You can now run that script (ex: ./spacetv.sh [full/path/to/movie.mp4] ). But you want to run it from SpaceFM. I do it this way:
          1- In SpaceFM, right click a file of the kind you want to be associated with the script (ex: a MP4 file) > “Open” > “Choose” > in “command”, in the bottom, write:
          /full/path/to/spacetv.sh %F
          Make sure to tick the box “set as default…”

          2- click any mp4 file – it will start playing in full screen. If you exit and click the same file, it will start from exactly where you were watching it…

          3- Optionally you can add a “tool” in the menu, calling it (for example) “Continue last movie”, and associate it with the command “~/spacetv.sh” (or the full path to your script) , this way you won’t even have to search for the last movies location in your drive…

          enjoy,

          P.

          • This reply was modified 2 years, 4 months ago by PPC.
          • This reply was modified 2 years, 4 months ago by PPC.
          #47887
          Member
          ex_Koo
            Helpful
            Up
            0
            ::

            PPC Thanks so much for the info I would never got there without your advice..

            Easy way to use that amazing little script:
            1- Go to https://raw.githubusercontent.com/IgnorantGuru/spacefm-plugins/master/ig-spacetv/src/cstm_325c1cf6/spacetv.sh and copy the script’s text
            2- Open a text editor (like geany), paste all the text you just copied and save it as “spacetv.sh” anywhere you want, like your home folder, for example
            3- Navigate to that script’s location and make it executable (select it, “CTRL+P”, make sure to check the “execute” box, click ok)
            4- You can now run that script (ex: ./spacetv.sh [full/path/to/movie.mp4] ). But you want to run it from SpaceFM. I do it this way:
            1- In SpaceFM, right click a file of the kind you want to be associated with the script (ex: a MP4 file) > “Open” > “Choose” > in “command”, in the bottom, write:
            /full/path/to/spacetv.sh %F
            Make sure to tick the box “set as default…”

            2- click any mp4 file – it will start playing in full screen. If you exit and click the same file, it will start from exactly where you were watching it…

            3- Optionally you can add a “tool” in the menu, calling it (for example) “Continue last movie”, and associate it with the command “~/spacetv.sh” (or the full path to your script) , this way you won’t even have to search for the last movies location in your drive…

            enjoy,

            P.

            • This reply was modified 2 years, 4 months ago by ex_Koo.
            #49905
            Member
            Robin
              Helpful
              Up
              0
              ::

              Just found that thread. This is really great! Thank you very much for sharing it, skidoo! Really amazing, I’ll probably make use of the functionality while creating graphical user interface for the script I’m about to write. I’ll still have to decide whether rather to use yad or to use this spaceFM.
              Robin

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

              #49908
              Member
              sleekmason
                Helpful
                Up
                0
                ::

                Thank you for finding this thread @Robin:)

                I’ve never really messed with Spacefm before and think it is pretty cool! Looks super customizable.

                I am wanting to add items to the right-click menu. Specifically:

                urxvt --hold -e ls -AghS --color %F

                — When added to tools works fine from the tools menu, but how to add items to the right-click menu?

                A hint that may help, but I can’t seem to enter properly is from:
                https://wiki.archlinux.org/index.php/SpaceFM

                MIME Type equals true
                File Is Dir equals true
                File Is Text equals true

                When entering in the context menu, anything I enter in the field shows up with: “MIME type begins with” appearing before the text.

                Not sure if getting this correct will allow for the right-click action, but getting it wrong will remove it from the tools menu, lol.

                *edit may have found the answer…

                – Custom actions > Right click in SpaceFM > In the active context menu right click again and note the options > then left click and the configuration dialog opens.

                Hard to find but it’s there. right-click, then DOUBLE right-click again on “NEW”, then left-click on Command. whew!

                • This reply was modified 2 years, 3 months ago by sleekmason.
                #49910
                Member
                PPC
                  Helpful
                  Up
                  0
                  ::

                  I am wanting to add items to the right-click menu. Specifically:

                  urxvt –hold -e ls -AghS –color %F

                  — When added to tools works fine from the tools menu, but how to add items to the right-click menu?

                  Easy: right click inside SpaceFM main window, where files are shown. On that menu, hover the mouse pointer above “Actions” and right click again. select the “+ New” … and select to add a “command”… Enter the command “name”, then, on the second window, the command itself (the “urxvt …” command)
                  You can also adapt that and place .desktop files on the SpaceFM toolbar (I placed the mount android device script, and my mount cloud drive scripts there)

                  P.

                  #49913
                  Member
                  sleekmason
                    Helpful
                    Up
                    0
                    ::

                    I am wanting to add items to the right-click menu. Specifically:

                    urxvt –hold -e ls -AghS –color %F

                    — When added to tools works fine from the tools menu, but how to add items to the right-click menu?

                    Easy: right click inside SpaceFM main window, where files are shown. On that menu, hover the mouse pointer above “Actions” and right click again. select the “+ New” … and select to add a “command”… Enter the command “name”, then, on the second window, the command itself (the “urxvt …” command)
                    You can also adapt that and place .desktop files on the SpaceFM toolbar (I placed the mount android device script, and my mount cloud drive scripts there)

                    P.

                    Thank you for your reply:)

                    Amazingly simple! I like Spacefm. Currently using both Thunar and Pcmanfm depending on use, and Spacefm looks closer to what I need. Don’t know why I haven’t messed with it before now. Think I may have installed it a few years back and didn’t like the default or something? anyway, glad to try it out again from a new perspective.
                    The spacetv plugin looks intriguing too.

                    #49919
                    Member
                    sleekmason
                      Helpful
                      Up
                      0
                      ::

                      Well, slightly stumped.
                      I am trying to get a simple “Open Terminal Here” working with:
                      urxvt -w %f

                      This will open a terminal in $HOME, but when I right-click on a file and Open In Terminal, it only opens an instance in $HOME and not the clicked file. Mime type inode/directory.

                      This is not a problem with two other commands that use urxvt as the terminal. Everything else is converting over nicely. Any ideas?

                      #49923
                      Anonymous
                        Helpful
                        Up
                        0
                        ::

                        Not specific to spaceFM, every terminal emulator seems to have quirks regarding how it expects (demands) arguments to be passed to it.

                        I’m not a regular user of urxvtpqrs, so I peeked at its manpage.
                        Per the manpage, -w expects an accompanying value.
                        Maybe your post just contains a typo, but it seems to amount to “dear urxvtpqrs, I want you to display a border, sized %filename pixels wide

                        Also, not specific to spaceFM (or, perhaps it is ~~ check your config) and not specific to launching any particular command… bear in mind that the launching app probably does not know, does not check, does not care which command processor shell (sh, vs ash dash bash zsh, et al) it is passing the launchstring to. If appropriate, your launchstring should explicitly request bash -c ‘blahblah’ (Appropriate, as in, when your launching syntax contains bash-isms.)

                        #49925
                        Member
                        sleekmason
                          Helpful
                          Up
                          0
                          ::

                          Not specific to spaceFM, every terminal emulator seems to have quirks regarding how it expects (demands) arguments to be passed to it.

                          I’m not a regular user of urxvtpqrs, so I peeked at its manpage.
                          Per the manpage, -w expects an accompanying value.
                          Maybe your post just contains a typo, but it seems to amount to “dear urxvtpqrs, I want you to display a border, sized %filename pixels wide”

                          Also, not specific to spaceFM (or, perhaps it is ~~ check your config) and not specific to launching any particular command… bear in mind that the launching app probably does not know, does not check, does not care which command processor shell (sh, vs ash dash bash zsh, et al) it is passing the launchstring to. If appropriate, your launchstring should explicitly request bash -c ‘blahblah’ (Appropriate, as in, when your launching syntax contains bash-isms.)

                          Yes, it is a weird one. Somehow the -w applies to the filemanager, not urxvt. Seems the expected format layout is wrong?

                          This holds true for thunar and pcmanfm as well, where the line above works as expected.
                          EDIT* Does NOT work in thunar. Works fine in Pcmanfm. For thunar use:
                          exo-open --working-directory %f --launch TerminalEmulator

                          But, I may not have a “real?” problem at all. I found after entering a sub directory (rather than just clicking on it), the action works as expected, opening in the current directory.

                          Might just be I don’t get to right-click on the file itself. I can live with that if this is the case.

                          *Edit – on further thought , it really should allow for it.
                          The ls command works as expected, as does this,
                          urxvt -e ncdu -rr %f
                          So even opening a separate program, both work as expected when right-clicking on a file. Why won’t the terminal itself?

                          • This reply was modified 2 years, 3 months ago by sleekmason.
                          • This reply was modified 2 years, 3 months ago by sleekmason.
                          #49935
                          Member
                          sleekmason
                            Helpful
                            Up
                            0
                            ::

                            This command works to set “Open Terminal Here”

                            exo-open --working-directory %f --launch TerminalEmulator

                            Spacefm is an awesome file manager:)

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