You are not logged in.

#101 2019-09-12 16:36:34

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

^ Thank you for the support. Where can I find out about Progress Bar PV?

Offline

#102 2019-09-12 18:13:32

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: The great yad hacking thread

^ It's a little command line app.
On my system it's a standalone package; try

apt install pv
man pv

It can do things like this:

echo -e "$(date)\b\b\b\b1984, $(uptime -p)"|pv -L 14 -q

Offline

#103 2019-09-14 10:41:36

clusterF
Member
Registered: 2019-05-07
Posts: 539

Re: The great yad hacking thread

Is there a way to create a yad dialog of web links, maybe buttons or just a list of clickable addresses? I wanting to create a menu of sorts that has all my favorite websites in a yad menu. Ive looked at the html options in yad but have no idea how to proceed.

Example;

button = bunsenlabs.org and xdg-opens inside x-www-browser ?

I have read you need yad built with the ./configure --html

and if you use yad --browser mode you need libwebkit2gtk.

Offline

#104 2019-09-14 13:25:55

damo
....moderator....
Registered: 2015-08-20
Posts: 6,734

Re: The great yad hacking thread

Another, simpler approach, is to create an OB menu item containing your links. This could be a submenu in your main menu; or a standalone menu run from a keybind, or a tint2 button/exec.


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#105 2019-09-14 14:56:31

clusterF
Member
Registered: 2019-05-07
Posts: 539

Re: The great yad hacking thread

^ that is an approach i had thought of. Seems yad doesnt really have good local web browser integration. I havent been able to figure out how to create a button that will open a link in my web browser. It would seem like a simple enough operation but i have googled and come up nil.

Offline

#106 2019-09-14 15:41:35

clusterF
Member
Registered: 2019-05-07
Posts: 539

Re: The great yad hacking thread

Figured something out. Having a separate txt file with html links helps.
links.txt needs full web address too like https://bunsenlabs.org

#!/bin/bash

yad --height=200 --width=150 --text-info --width=250 < $HOME/Documents/links.txt --show-uri \
--button=gtk-cancel:1

Last edited by clusterF (2019-09-14 15:44:03)

Offline

#107 2019-09-14 17:46:30

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

^ I would like to answer the question of the user cluserF and insert a picture. However, the png file does not work. How does that work?

Offline

#108 2019-09-14 18:28:00

damo
....moderator....
Registered: 2015-08-20
Posts: 6,734

Re: The great yad hacking thread

achim wrote:

^ I would like to answer the question of the user cluserF and insert a picture. However, the png file does not work. How does that work?

Use an [ img ] tag in your post edit window.

bunsenlabs wrote:

Please use thumbnails. Do not embed images larger than approx 250x250px (62,500px) into posts, use thumbnails linking to a hosted image instead. Thanks!

We recommend https://scrot.moe (free registration required) for image uploads. After uploading your image, click "Embed codes" and copy/paste the "Thumbnail image (linked) BBCode" at the bottom of the page, done.

Your post will have something like

[url=https://url-of-full-image][img]url-of-thumbnail.png[/img][/url] 

Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#109 2019-09-15 09:36:13

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

Thanks to the moderator. I try it differently.

@ clusterF
I've built myself a very flexible htm file. This does not have anything to do with YAD, but if you're interested, please let me know by PM.

achim

Offline

#110 2019-09-15 10:46:55

clusterF
Member
Registered: 2019-05-07
Posts: 539

Re: The great yad hacking thread

@achim

Its ok, im just experimenting with yad. I wanted to see if i can create a button that links to a website and some other fields mixed together in the one yad window.

Offline

#111 2019-09-17 06:51:16

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: The great yad hacking thread

clusterF wrote:

Figured something out. Having a separate txt file with html links helps.

--show-uri

That's a nice option.
And they just open in your chosen default browser?

Offline

#112 2019-09-17 12:31:03

clusterF
Member
Registered: 2019-05-07
Posts: 539

Re: The great yad hacking thread

ohnonot wrote:
clusterF wrote:

Figured something out. Having a separate txt file with html links helps.

--show-uri

That's a nice option.
And they just open in your chosen default browser?

Yes apparently that will use xdg-open into your default browser.

From man yad in "Text Info Operations"

--show-uri
              Make links in text clickable. Links opens with xdg-open command.

Offline

#113 2019-09-21 15:28:30

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

Hello everybody,

I have installed a YAD script on a notebook with the operating system Linux Mint 18.3 - 64 Bit, in which the code line "--no-buttons --close-on-unfocus" does not work. Therefore, a question: does anyone have a similar problem or knows a solution? Here is the code:

#!/bin/sh
#
# Start-Center für verschiedene YAD-Scripts
#
TEXT="<span foreground='blue'><b><big><big>
Linux Tools

Bitte einen Modus wählen:
</big></big></b></span>"

yad --borders=50 --center --columns=2 --window-icon="$HOME/.icons/system22.png" --title="Achim's Linux-Tools Start Center" --form \
--width=800 --height=500 --fixed --text="$TEXT" \
--image="gtk-execute" \
--image-on-top \
--field="Backup / Restore":fbtn "tback.sh" \
--field="Handy auslesen":fbtn "tcopycam.sh" \
--field="Änderungsdatum Bilder":fbtn "toedat.sh" \
--no-buttons --close-on-unfocus

Greetings,
achim

Last edited by achim (2019-09-21 15:32:20)

Offline

#114 2019-09-21 18:02:08

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

That will be so. It is the version 0.27 from the package of .Linux-Mint 18.3. Oddly, my desktop PC with Tower, also LM 18.3, uses version 0.39. Can I actually install a higher version without problems?

Offline

#115 2019-09-22 16:27:08

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

thanks

Offline

#116 2019-11-01 19:46:57

Anton
Member
From: СПб, Россия
Registered: 2019-04-11
Posts: 9

Re: The great yad hacking thread

misko_2083 wrote:

Да си жив и здрав.
You'll figure it out eventually.

I like to help but realy don't want to run those BLOBs in the archive.
It's more than enough having all those proprietary BLOBs in the linux kernel. smile

Done.

Offline

#117 2019-11-02 18:29:50

Anton
Member
From: СПб, Россия
Registered: 2019-04-11
Posts: 9

Re: The great yad hacking thread

misko_2083.
For example: Free game with it.
Look it (cat merged file) in action.
Installer template.
Thank you again for your help.

Last edited by Anton (2019-11-08 09:34:50)

Offline

#118 2019-11-02 20:03:54

Anton
Member
From: СПб, Россия
Registered: 2019-04-11
Posts: 9

Re: The great yad hacking thread

misko_2083 wrote:

Found a use for the html dialog.
Made a fake title bar in a yad's paned window.
https://i.imgur.com/a6NX9hAm.png

Used xdotool, xprop, wmctrl, CSS, HTML, bash and C (Xlib). Fun smile
https://www.youtube.com/watch?v=cwJMRKAQAMU

Where is the code?
RTX and lika is me there.

Last edited by Anton (2019-11-02 20:04:28)

Offline

#119 2019-11-07 22:06:07

Anton
Member
From: СПб, Россия
Registered: 2019-04-11
Posts: 9

Re: The great yad hacking thread

misko_2083 wrote:

I've searched the forums for yad installer on rutracker.org and found some games than are not free.
htps://rutracker.org/forum/viewtopic.php?t=5696248
https://rutracker.org/forum/viewtopic.php?t=5630907
https://rutracker.org/forum/viewtopic.php?t=5497249
My initial conclusion was that you are captaing Jack Sparrow.
Apologies if not so.

Posted the code in the google groups.
I try to preserve the free space on the server of this forum.

There is "Games for Linux" section.
There is no point publishing opensource/free games on that site (although they are, but they are very rare there).
I have been making repacks (90% bought by me) with earlier YSI versions since the end of August 2018. I started making installer with Zenity in the spring of 2018, but in the middle of summer 2018 I found out about YAD (on http://murga-linux.com/puppy/viewtopic.php?t=97458).

//07.11.2019 — YSI links updated

Last edited by Anton (2019-11-08 09:39:16)

Offline

#120 2019-11-26 14:56:20

achim
Member
Registered: 2019-08-23
Posts: 40

Re: The great yad hacking thread

Good day everybody,

I want to generate a printer selection in a yad-script. Installed printers are currently

EPSON WF-3520 series
pc-fax
Generic CUPS-PDF Printer

So far I solve the conversion somewhat with "lpoptions -d" EPSON_WF-3520_Series "or" lpr -P PDF ".
How do I achieve a change if I do not know the printer name? I'm looking for a way to convert the printer via script by the installed printers are read and then offered via yad for selection. Is anyone familiar with it?

achim

Offline

Board footer

Powered by FluxBB