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 Tue 23 Jul 2019, 13:50
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
YAD - Tips
Post new topic   Reply to topic View previous topic :: View next topic
Page 5 of 42 [630 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, ..., 40, 41, 42 Next
Author Message
rg66


Joined: 23 Jul 2012
Posts: 1160
Location: Vancouver, BC Canada / Entebbe, Uganda Africa!?!

PostPosted: Mon 08 Jun 2015, 22:23    Post subject: Re: right click hidden files option  

seaside wrote:
Try this.

Create below file and put at " /root/.config/gtk-2.0/gtkfilechooser.ini"

Code:
# /root/.config/gtk-2.0/gtkfilechooser.ini
[Filechooser Settings]
ShowHidden=true


All gtkfilechooser calls should now show hidden files.

Cheers,
s


Works like a charm, thanks seaside

_________________
X-slacko-5b1 - X-tahr-2.0 - X-precise-2.4
X-series repo
Back to top
View user's profile Send private message 
slavvo67

Joined: 12 Oct 2012
Posts: 1600
Location: The other Mr. 305

PostPosted: Tue 09 Jun 2015, 00:32    Post subject:  

Good idea if you don't mind having YAD show all your hidden files / folders. I guess if you just want to see them for one particular YAD program and not the others, the right click option is still the way to go.

Thank you all for the suggestions, though. I have a feeling there will eventually be a fix in YAD for this.
Back to top
View user's profile Send private message 
rg66


Joined: 23 Jul 2012
Posts: 1160
Location: Vancouver, BC Canada / Entebbe, Uganda Africa!?!

PostPosted: Sat 05 Sep 2015, 03:12    Post subject:  

Just discovered that you can use markup for buttons.

Code:
yad --button="<b><span color='red'>Test</span></b>" --button="<b><span color='blue'>Test</span></b>"
yad.jpg
 Description   
 Filesize   5.84 KB
 Viewed   2542 Time(s)

yad.jpg


_________________
X-slacko-5b1 - X-tahr-2.0 - X-precise-2.4
X-series repo
Back to top
View user's profile Send private message 
slavvo67

Joined: 12 Oct 2012
Posts: 1600
Location: The other Mr. 305

PostPosted: Tue 08 Sep 2015, 00:43    Post subject:  

Thanks RG66. Another worthy addition to the test scripts.
Back to top
View user's profile Send private message 
slavvo67

Joined: 12 Oct 2012
Posts: 1600
Location: The other Mr. 305

PostPosted: Wed 09 Sep 2015, 18:11    Post subject:  

For those that might not be aware, YAD supports columns since about version 25. Importantly, if you write a script with the --columns= and run it unknowingly on a puppy with an older version of YAD; it will make a mess.

Quick example below:

yad --title='Website Choice' --text='Paste Site or Sites Here' --form --columns=2 --field='Website Name 1' --form --field='Website Name 2' --form --field='Website Name 3' --form --field='Website Name 4' --form --field='Website Name 5' --form --field='Website Name 6' --form --field='Website Name 7' --form --field='Website Name 8' --form --field='Left Blank' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment'
Back to top
View user's profile Send private message 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Sun 27 Sep 2015, 16:47    Post subject: yad-0.31.0
Subject description: latest yad version
 

Hi all,

I've compiled the latest yad (0.31.0).

I shouldn't be compiling as I am not a developer. But frustration sometimes is the mother of invention Wink

On my hardware, Puppy Precise (5.7.1 or 5.7.2) proved to be by far the most reliable puppy. But it comes with a very old yad version (0.12.4, or something like that).

More frustration: the slacko yad-0.27.pet, kindly offered by rg66 on page 4 of this thread, does not work in Puppy Precise.

So I compiled yad 0.31.0 in Puppy Precise, to enable Precise users to enjoy the most recent YAD. It might work in other puppy's, but I haven't tested that.

So...no guarantees, except that it works well in Puppy 5.7.1 and derivates.

[EDIT[The download is no longerhere. (superseded by better and more recent version by stemsee[/edit]

_________________



Last edited by Bert on Sun 11 Oct 2015, 16:03; edited 1 time in total
Back to top
View user's profile Send private message 
stemsee

Joined: 27 Jun 2013
Posts: 2363
Location: In The Way

PostPosted: Mon 28 Sep 2015, 04:26    Post subject:  

It is working great on dpup wheezy! Cheers!
Back to top
View user's profile Send private message MSN Messenger 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Mon 28 Sep 2015, 12:03    Post subject:  

Thanks for testing and reporting back stemsee Cool
_________________


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


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Mon 28 Sep 2015, 12:21    Post subject:  

It seems Victor Ananjevsky keeps adding wonderful stuff to his yad treasure chest...and then lets us search for the key Laughing Many of the new capabilities sound great, but it's not easy to discover how to use them.

Here's part of the "NEWS" file, found in the sources:
Quote:
Version 0.31.0
- add separators to list dialog
- use YAD_OPTIONS variable for specify default yad arguments
- add --no-rules-hint option to list dialog
- add parameters for controlling palletes in color selection
- remove some entries from settings file
- set default open command and date format through the settings file
- add additional filter settings for file selection dialogs
- apply filter and preview settings to all of file selection dialogs
- fix settings custom icon theme

Version 0.30.1
- fix parsing paned orientation

Version 0.30.0
- add paned dialog
- add --parent-win option to make dialog transient for special window
- add --uri-color option for setting text color of URIs in text-info dialog

Version 0.29.1
- fix build without HTML dialog

Version 0.29.0
- fix focus problems in html dialog
- set default encoding from locale for html widget
- fix quoted output in form dialog
- add --no-escape option to prevent close dialog when Esc is pressed
- show gtk version within --version and about dialog
- fix build with gcc 5.x

Version 0.28.1
- fix incorrect rows output order in form dialog

Version 0.28.0
- add HTML dialog
- add different output formats for color dialog
- add mnemonic feature for field labels in form and entry dialogs
- add completion entry as field type in form dialog
- add output by rows in form dialog when layout with several columns is used
- fix labels in multiprogress dialog
- fix print to file in print dialog
- fix setup arguments for double-click action in list dialog
- update man page

Version 0.27.0
- add --hidden option to notification icon
- add --tooltip-column option to list dialog
- add --gtkrc option
- fix detection of expandind columns in list dialog
- fix markup handling
- add YAD_XID variable for dialogs children
- code cleanup for remove deprecated api

Version 0.26.1
- fix output in list dialog for check and radiolists
- fix button alignment in form dialog
- don't add last item separator in multifile field of form dialog

Version 0.26.0
- double-click actions in list dialog can change values in current row
- impove handling of markup text in list dialog
- add FBTN field type (relief buttons) to form dialog
- add buttons with custom icons
- add labels with icons for tab labels in notebook dialog
- remove --align option for notebook dialog
- numeric entries aligned to the right side

Version 0.25.1
- use normal window hints for dialog windows
- fix menu in notification icon (issue #196)

Version 0.25.0
- add --menu option for notification icon
- add --maximized and --fullscreen options
- unify --listen option for different kind of dialogs
- replace --stdin option by --listen in icon dialog

Vesrion 0.24.1
- fix parsing menu in notification dialog

Version 0.24.0
- add --auto-close option for multi-progress dialog
- add --image-path option
- add --no-click option to list dialog
- allow clear text in text-info dialog with ^L
- new translations
- bug fixes

Version 0.23.1
- wait for child termination in notebook dialog
- honour custom width and height settings in unresizable dialogs

Version 0.23.0
- add --quoted-output option for file, form and list dialogs
- add default values for combo-box field in form dialog
- fix dialogs responses when working in notebook mode

Version 0.22.1
- fix resize of dialog text
- fix usage of stock items in popup menu of notification icon

Version 0.22.0
- add scale field to form dialog
- fix form layout on gtk+-3.0
- fix borders around child dialogs in notebook
- fix handle stdin for icons dialog in compact mode
- fix dialog text alignment
- add italian translation
- update man page

Version 0.21.0
- add optional scrollbars for form dialog
- add "duplicate row" menu entry for editable lists
- some fixes in man page

Version 0.20.3
- update slovak translation
- use double-ckick for selecting date in form dialog
- fix check field layout in form dialog for gtk3

Version 0.20.2
- fix tooltips in list dialog

Version 0.20.1
- fix --kill-parent option

Version 0.20.0
- default value for combo-box can be specified by --entry-text from one of existings entries in list
- add --single-click option for icon dialog
- add log window to progress dialog
- fix geometry settings for unresizable windows
- fix layout on gtk3
- add custom signals for --kill-parent option

Version 0.19.1
- use current path as a default folder for file selection dialogs
- fix parsing .desktop files in icons dialog

Version 0.19.0
- add preview to file dialog
- recognize link type in .desktop files for icon dialog
- make icon description selectable in icon browser
- fix quoting special characters when pass data to the command in list and dnd dialogs

Version 0.18.0
- add notebook dialog
- add --button-layout option
- use markup for bar labels in multiprogress dialog
- make --align works for multi-progress too
- fix --geometry behavior
- fix wrap for multiline text fields in form dialog
- add radio and hidden column types in list dialog
- add @disabled@ value to form dialog
- add precisions to form and entry numeric fields
- add --listen option to list and text dialogs

Version 0.17.1.1
- fix --listen mode of notification

Version 0.17.1
- fix build with gtk+ < 2.22
- add wrapping to multiline text field in form dialog
- fix search in text-info dialog
- fix handling empty strings in --listen mode of notification
- add traditional chinese translation

Version 0.17.0
- add search in --text-info dialog (activate by pressing Ctrl+S)
- add multiline text field to form dialog
- add multiply directory selection to form dialog
- add --rest option for specify extra command-line options through the external file
- add new setting "ignore_unknown_options"
- list dialog now can handle command-line and stdin data at the same time
- sending "^L" to list dialog will clear the list

Version 0.16.3
- fix text settings in text-info dialog on gtk3
- fix --percentage option in progress dialog
- recognize special characters like \n in form labels

Version 0.16.2
- always set first item as active for combo-box in entry dialog
- fix includes in print for build with gtk3

Version 0.16.1
- add initial sorting to yad icon browser
- remove some deprecated calls
- fix build with gtk+-3.0

Version 0.16.0
- add printing dialog
- add callbacks for dialog buttons
- add icons for popup menu in notification icon
- add french translation
- make Return works for combo-boxes in entry dialog
- change notification behavior. if --listen is specified, left click on icon
doesn't close it
- add --text-align option for aligning dialog text

Version 0.15.1
- fix grid placement in form dialog
- fix popup menu in editable lists
- fix escaping markup text
- update man page

Version 0.15.0
- add multiple progress bars dialog
- add field control for buttons in form dialog
- keep current directory in auxiliary file selectors in form dialog
- add tooltips for form buttons
- add new field types: SFL for create new file and CDIR for create new dir
- add --tooltip option for dnd dialog
- fix setting initial value for numeric field in form dialog
- add --print-xid option
- for progress dialog the default button is gtk-close now
- user can specify gtk version in ./configure script
- new yad icons (special thanks to Bogdan Lisovich)

Version 0.14.2
- fix broken dialog text placement

Version 0.14.1
- fix build with gtk3

Version 0.14.0
- add regex search to list dialog
- add --page option for scale dialog
- add marks to scale dialog
- add expander for main widget
- bug fixes

Version 0.13.0
- fixes for icons in entry dialog
- add icons for editable combo-boxes in entry dialog
- add new field types for form dialog - labels and buttons
- fix blinking behavior in notification icon
- some improvements in user-defined double-click action for list dialog
- dialog text can be selected if --selectable-labels specified
- fix image clipping in gtk+-3.0
- fix tooltips in list dialog
- fix wrapping dialog's text
- add --border option for set margins around dialog widgets
- add names for widgets for customize dialog look&feel through .gtkrc
- fix handling window icon

_________________


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


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Mon 28 Sep 2015, 18:51    Post subject:  

slavvo67 wrote:
For those that might not be aware, YAD supports columns since about version 25. Importantly, if you write a script with the --columns= and run it unknowingly on a puppy with an older version of YAD; it will make a mess.

Quick example below:

yad --title='Website Choice' --text='Paste Site or Sites Here' --form --columns=2 --field='Website Name 1' --form --field='Website Name 2' --form --field='Website Name 3' --form --field='Website Name 4' --form --field='Website Name 5' --form --field='Website Name 6' --form --field='Website Name 7' --form --field='Website Name 8' --form --field='Left Blank' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment' --form --field='Name or Comment'


Hi slavvo67,

Thanks for the "--columns=" example!

To make things easier, I think "--form" needs to be written only once:

Code:
yad --title='Website Choice' --text='Paste Site or Sites Here' --form --columns=2 --field='Website Name 1' --field='Website Name 2' --field='Website Name 3' --field='Website Name 4' --field='Website Name 5' --field='Website Name 6'  --field='Website Name 7' --field='Website Name 8' --field='Left Blank' --field='Name or Comment' --field='Name or Comment' --field='Name or Comment' --field='Name or Comment' --field='Name or Comment'


Thanks again. I'd never seen a '--columns=' example before!
image-1.png
 Description   
 Filesize   24.06 KB
 Viewed   2416 Time(s)

image-1.png


_________________


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

Joined: 12 Oct 2012
Posts: 1600
Location: The other Mr. 305

PostPosted: Tue 29 Sep 2015, 00:32    Post subject:  

Please refer to Smokey01's first post for a quick YAD manual. Of course, it doesn't take into account all the additions.
Back to top
View user's profile Send private message 
smokey01


Joined: 30 Dec 2006
Posts: 2811
Location: South Australia :-(

PostPosted: Tue 29 Sep 2015, 00:35    Post subject:  

Not yet but the plan is to include them.

Cheers.

_________________
Software <-> Distros <-> Tips <-> Newsletters
Back to top
View user's profile Send private message Visit poster's website 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Tue 29 Sep 2015, 07:53    Post subject:  

Yes, I have smokey01's tutorial available.
In fact, smokey01's initiative gave me the courage to reconsider learning YAD. Wink Earlier attempts just drove me crazy...

When I'm in another OS than Puppy, I can still read the Yad-Tips in the browser. Nice.

So, thanks for your work smokey01! Scripting, bash, etc. are not my forte, but if I discover something new in yad, I will certainly share it here. Smile

_________________


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


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Wed 30 Sep 2015, 11:50    Post subject: Custom icons and tooltips for buttons  

This is new to me: custom icons and tooltips for buttons:

Code:

#!/bin/bash
#
yad --button="Worldsoup!/usr/local/lib/X11/themes/JQ8raised/www48.png:fbtn!" \
       --button="Hi there!gtk-preferences" \
       --button="Hello!/usr/local/lib/X11/pixmaps/phone48.png!hellohello?" \
       --button="Byebye!/usr/local/lib/X11/themes/Moka/shutdown24.png!see you later" \


EDIT: I made a mistake.. at the end of the first button line the ":fbtn" and the "!" are not needed. The ":fbtn" is for form-field-buttons and the "!" is only needed when followed by a tooltip. For normal buttons the structure is simple: "Text!Icon!Tooltip"

So the above code should be:
Code:

yad --button="Worldsoup!/usr/local/lib/X11/themes/JQ8raised/www48.png" \
       --button="Hi there!gtk-preferences" \
       --button="Hello!/usr/local/lib/X11/pixmaps/phone48.png!hellohello?" \
       --button="Byebye!/usr/local/lib/X11/themes/Moka/shutdown24.png!see you later"

[/EDIT]
Available in YAD 0.26.0 and higher.
image-1.png
 Description   
 Filesize   18.23 KB
 Viewed   2387 Time(s)

image-1.png


_________________


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


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Wed 30 Sep 2015, 13:19    Post subject: "form-field-button"  

A quick example of "form-field-buttons"

Code:
#!/bin/sh

yad --form \
       --field="PETS!/root/spot/spot.png!Isn't tha spot? :fbtn" \
       --field="STEP!/root/spot/spot2.png:fbtn" \
       --field="PETS"
yad-form-field-button.png
 Description   
 Filesize   23.59 KB
 Viewed   2372 Time(s)

yad-form-field-button.png


_________________


Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 5 of 42 [630 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, ..., 40, 41, 42 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Off-Topic Area » Programming
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.0774s ][ Queries: 12 (0.0139s) ][ GZIP on ]