Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Mon 18 Nov 2019, 18:40
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
mukstart - start menu like Cinnamon
Post new topic   Reply to topic View previous topic :: View next topic
Page 3 of 4 [46 Posts]   Goto page: Previous 1, 2, 3, 4 Next
Author Message
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Tue 06 Sep 2016, 00:49    Post subject:  

Thank You Peebee,
How to fill vertically in gtkdialog? anyone know?
peebee wrote:
a few application icons are not picked up or are wrong size

Yes, I also got the same, it is no picked up
Back to top
View user's profile Send private message 
MochiMoppel


Joined: 26 Jan 2011
Posts: 1925
Location: Japan

PostPosted: Wed 07 Sep 2016, 08:28    Post subject:  

recobayu wrote:
How to fill vertically in gtkdialog? anyone know?
What do you mean by "fill vertically"?
Back to top
View user's profile Send private message 
peebee


Joined: 21 Sep 2008
Posts: 4053
Location: Worcestershire, UK

PostPosted: Wed 07 Sep 2016, 08:44    Post subject:  

MochiMoppel wrote:
recobayu wrote:
How to fill vertically in gtkdialog? anyone know?
What do you mean by "fill vertically"?

It means that the space occupied by the 2 trees expands horizontally if the window is resized but does not expand vertically - it is fixed at the height of the left hand tree.

To see - open mukstart and then resize the window by dragging on the corner....

_________________
LxPup = Puppy + LXDE
Main version used daily: LxPupSc; Assembler of UPups, ScPup & ScPup64, LxPup, LxPupSc & LxPupSc64
Back to top
View user's profile Send private message Visit poster's website 
MochiMoppel


Joined: 26 Jan 2011
Posts: 1925
Location: Japan

PostPosted: Wed 07 Sep 2016, 09:31    Post subject:  

peebee wrote:
It means that the space occupied by the 2 trees expands horizontally if the window is resized but does not expand vertically - it is fixed at the height of the left hand tree.

To see - open mukstart and then resize the window by dragging on the corner....

I thought it was about adjusting window height to the tree height at startup (very tricky), not manual resizing. I can't see anything because I never was able to run mukstart. I now made my 3rd attempt with the newest version and I get this:
Code:
** (gtkdialog:30092): ERROR **: gtkdialog: Error in line 325, near token '</vbox>': syntax error

./mukstart: line 286: 30092 Trace/breakpoint trap   gtkdialog -f /usr/local/mukstart/gui --geometry +"0"+"0"


BTW: The </vbox> error is cause by an empty vbox in /usr/local/mukstart/gui. Gtkdialog doesn't like that:
Code:
         </button>
</vbox>
<vbox scrollable="true" width="300">
</vbox>
<vbox scrollable="true" width="300">
<button xalign="0">
Back to top
View user's profile Send private message 
peebee


Joined: 21 Sep 2008
Posts: 4053
Location: Worcestershire, UK

PostPosted: Wed 07 Sep 2016, 12:12    Post subject:  

MochiMoppel wrote:
peebee wrote:
It means that the space occupied by the 2 trees expands horizontally if the window is resized but does not expand vertically - it is fixed at the height of the left hand tree.

To see - open mukstart and then resize the window by dragging on the corner....

I thought it was about adjusting window height to the tree height at startup (very tricky), not manual resizing. I can't see anything because I never was able to run mukstart. I now made my 3rd attempt with the newest version and I get this:
Code:
** (gtkdialog:30092): ERROR **: gtkdialog: Error in line 325, near token '</vbox>': syntax error

./mukstart: line 286: 30092 Trace/breakpoint trap   gtkdialog -f /usr/local/mukstart/gui --geometry +"0"+"0"


BTW: The </vbox> error is cause by an empty vbox in /usr/local/mukstart/gui. Gtkdialog doesn't like that:
Code:
         </button>
</vbox>
<vbox scrollable="true" width="300">
</vbox>
<vbox scrollable="true" width="300">
<button xalign="0">

Latest version (not a .pet - just a shellscript) is at:
http://www.murga-linux.com/puppy/viewtopic.php?p=921953#921953

Works OK for me.....

_________________
LxPup = Puppy + LXDE
Main version used daily: LxPupSc; Assembler of UPups, ScPup & ScPup64, LxPup, LxPupSc & LxPupSc64
Back to top
View user's profile Send private message Visit poster's website 
MochiMoppel


Joined: 26 Jan 2011
Posts: 1925
Location: Japan

PostPosted: Wed 07 Sep 2016, 21:56    Post subject:  

The script works better.

To expand the tree vertically add:
Line 167: <notebook show-tabs="false" show-border="false" space-expand="true" space-fill="true">
Line 206:<text xalign="1" space-expand="false">
Back to top
View user's profile Send private message 
peebee


Joined: 21 Sep 2008
Posts: 4053
Location: Worcestershire, UK

PostPosted: Thu 08 Sep 2016, 11:42    Post subject:  

MochiMoppel wrote:
The script works better.

To expand the tree vertically add:
Line 167: <notebook show-tabs="false" show-border="false" space-expand="true" space-fill="true">
Line 206:<text xalign="1" space-expand="false">

Thank you @MochiMoppel - that does the trick - but also changing line 169 to:

<tree rules-hint="false" headers-visible="false" hover-selection="true" space-expand="false" space-fill="false">

makes it even better....

_________________
LxPup = Puppy + LXDE
Main version used daily: LxPupSc; Assembler of UPups, ScPup & ScPup64, LxPup, LxPupSc & LxPupSc64
Back to top
View user's profile Send private message Visit poster's website 
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Fri 09 Sep 2016, 03:30    Post subject:  

Another exploration.
Code:

#!/bin/sh
Pil='Accessibility|Desktop|Screensaver'
grep -El "^Categories=.*($Pil)" /usr/share/applications/*>lok
grep "^Name=" `cat lok`|cut -d\= -f2>nama
grep "^Icon=" `cat lok`|cut -d\= -f2>ikon
grep "^Exec=" `cat lok`|cut -d\= -f2>exe

buatbutton(){
   howmuchline=$(wc -l lok|cut -d" " -f1)
   for i in $(seq 1 $howmuchline);do
      ikonku=$(sed -n $i\p ikon)
      namaku=$(sed -n $i\p nama)
      exeku=$(sed -n $i\p exe)
      if [[ $ikonku != *\/* ]];then
         for i in mini-icons pixmaps;do
            if [ -f /root/puppy-reference/$i/$ikonku ];then
               ikonku=/root/puppy-reference/$i/$ikonku
            fi
         done
      fi
      echo '
      <hbox space-fill="true" space-expand="true">
      <button space-fill="false" space-expand="false" relief="2">
         <input file>'$ikonku'</input>
         <label> '$namaku'</label>
         <action>'$exeku'&</action>
         <action>EXIT:exit</action>
         <width>24</width>
      </button>
      <text><label>""</label></text>
      </hbox>'
   done
      
}

export -f buatbutton

export gui='
<window>
   <vbox scrollable="true" width="300" height="500">
      '"`buatbutton`"'
   </vbox>
</window>'
gtkdialog -p gui

This code gave me a clue.. maybe using button is better
buttonleft.png
 Description   This look better, isn't it?
 Filesize   38.73 KB
 Viewed   477 Time(s)

buttonleft.png

Back to top
View user's profile Send private message 
peebee


Joined: 21 Sep 2008
Posts: 4053
Location: Worcestershire, UK

PostPosted: Sat 24 Sep 2016, 05:49    Post subject: YA-Menu  

Here is my take on a menu app - heavily based on the excellent work by recobayu but with quite a lot of changes....mainly aimed at LxPup but also works on jwm based pups....

When I have time I'll probably add "Favourites" and "Recently Used" facilities....

Cheers
peebee

p.s. also works on xslacko (but is very similar to the XFCE menu)
Screenshot.png
 Description   
 Filesize   73.19 KB
 Viewed   390 Time(s)

Screenshot.png

yamenu-1.pet
Description 
pet

 Download 
Filename  yamenu-1.pet 
Filesize  3.43 KB 
Downloaded  262 Time(s) 

_________________
LxPup = Puppy + LXDE
Main version used daily: LxPupSc; Assembler of UPups, ScPup & ScPup64, LxPup, LxPupSc & LxPupSc64
Back to top
View user's profile Send private message Visit poster's website 
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Sat 24 Sep 2016, 23:45    Post subject:  

That is great, Peebee..
Thank you very much. Very Happy
Back to top
View user's profile Send private message 
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Sun 01 Sep 2019, 13:06    Post subject: Muksearch  

I was inspired by windows 10 search. Now it is separate with cortana.
I make it simple. The good news is, if we search an app and run it now, it become on the top of search list on the next search.
I also add recent apps button (max 5 apps) and recently used doc (thank you MochiMoppel, I use your code).
We can add shortcut it (i.e: shift+win or win+space). Please rename the fake gz and run it.
I hope you like it. Thank you.
app_tobe_the_first.png
 Description   We run an App. On the next run, the app become on the first list
 Filesize   56.02 KB
 Viewed   212 Time(s)

app_tobe_the_first.png

recent_apps.png
 Description   Empty search box. It shows recent apps and recently used document
 Filesize   66.65 KB
 Viewed   213 Time(s)

recent_apps.png

190901_2224_muksearch.gz
Description  remove fake gz
gz

 Download 
Filename  190901_2224_muksearch.gz 
Filesize  7.85 KB 
Downloaded  59 Time(s) 
Back to top
View user's profile Send private message 
MochiMoppel


Joined: 26 Jan 2011
Posts: 1925
Location: Japan

PostPosted: Sun 01 Sep 2019, 22:06    Post subject: Re: Muksearch  

recobayu wrote:
thank you MochiMoppel, I use your code
You're welcome, but that's not exactly my code Wink
Always make sure that you test your code with file names that contain spaces.

I suggest that in line 217 you change
Code:
<action signal="button-release-event">rox -s $tree_recent</action>
to
Code:
<action signal="button-release-event">rox -s "$tree_recent"</action>



[Edit]
If you like you can try to replace the generic folder icons with each file's ROX mime icon:

1) symlink the ROX icons
Code:
ln -fsn /usr/local/apps/ROX-Filer/ROX/MIME/ ${muksdir}/icons
( Your assignment "export XDG_DATA_DIRS=$XDG_DATA_DIRS:$muksdir" needs no change)

1) Change the function. The sed command now fetches also the mime-type. I omitted the if command as it's most likely not needed.
Code:
recently_used(){
   rm $muksdir/recent
   rm $muksdir/recent_all
   XBEL_PATH=/root/.local/share/recently-used.xbel
   IFS=$'\n'
   MAX_ITEMS=20
   printf -v ALL "$(sed -rn 's/%/\\x/g
   /href=/   {N;N;N;N;s_^.*file://([^ "]*).*modified="([^"]*).*mime-type type="([^"]*).*$_\2@\3|\1_p}
   ' "$XBEL_PATH" | sort -r | sed 's/.*@//; s_/_-_')"

   for file in $ALL ;do
   [[ -e ${file#*|} ]] && CNT=$((CNT+1)) && echo "$file" >> $muksdir/recent
   ((CNT==MAX_ITEMS)) && break
   done      
}


3) Change the tree:
Code:
   <tree rules-hint="true" headers-visible="false" hover-selection="true">
     <height>400</height>
     <width>600</width>
     <action signal="button-release-event">rox -s "$tree_recent"</action>
     <action signal="button-release-event">EXIT:exit</action>
     <action>rox -s "$tree_recent"</action>
     <action>EXIT:exit</action>
     <input file icon-column="0">'$muksdir'/recent</input>
     <variable>tree_recent</variable>
   </tree>
Back to top
View user's profile Send private message 
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Tue 03 Sep 2019, 01:07    Post subject:  

Thank you, MochiMoppel.. I like it.
Please download file gz attachment below. rename it manually. it is not real gz file.

Improvement:
-Recent activities icon is based on mime icon the file. Thank you Mochimoppel.. Very Happy
-Colored text recent apps and recent activities
-If we click button on recent apps, it become the first on the next run
-fix the "$tree_recent".
-fix for sudoku.
-file /root/.muksearch/topapps keep small (keep only 5 line)
-notebook also expand vertically when the window resize vertically
-exit by press escape key
190903_1705_muksearch.gz
Description  remove fake gz
gz

 Download 
Filename  190903_1705_muksearch.gz 
Filesize  8.11 KB 
Downloaded  59 Time(s) 
not searching.png
 Description   The default screen, now support icon based on type of file. 39 Mochimoppel..
 Filesize   63.94 KB
 Viewed   133 Time(s)

not searching.png


Last edited by recobayu on Fri 06 Sep 2019, 06:05; edited 1 time in total
Back to top
View user's profile Send private message 
MochiMoppel


Joined: 26 Jan 2011
Posts: 1925
Location: Japan

PostPosted: Tue 03 Sep 2019, 07:30    Post subject:  

Looks good!
One thing you may want to reconsider is the MAX_ITEMS limitation. This limitation makes sense in a menu, for which this routine was originally written, but you have a scrollbar in your window and speed is not as crucial as in case of a menu. Probably eliminating MAX_ITEMS and CNT would have no negative effects.
Back to top
View user's profile Send private message 
recobayu


Joined: 15 Sep 2010
Posts: 366
Location: indonesia

PostPosted: Fri 06 Sep 2019, 04:09    Post subject:  

The problem appear after I install a new app. It doesn't appear in mukstart. So I create this update. Now it was fixed. The recent apps still on top of list. and the new app will add in daftarlengkap.

Thank you Mochimoppel, now the recent activities more than 20.
it also can run in terminal where the file has "Terminal=true". Example: python.

Thank you
190906_1520_muksearch.gz
Description  remove fake gz
gz

 Download 
Filename  190906_1520_muksearch.gz 
Filesize  8.98 KB 
Downloaded  53 Time(s) 
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 3 of 4 [46 Posts]   Goto page: Previous 1, 2, 3, 4 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0910s ][ Queries: 13 (0.0156s) ][ GZIP on ]