getting --editable text from --text-info

46 views
Skip to first unread message

dave

unread,
Sep 6, 2020, 12:17:37 AM9/6/20
to yad-common
This is paned dialog from a working script
============================================
yad --plug=$KEY --tabnum=1 --text-info --show-uri --back="#456787" --fore=white --always-print-result --center --wrap --window-icon="text-editor" --editable --filename="$FILE" > /tmp/testynotes.txt &> res1 &

. /tmp/newfile &

yad --paned --title="$f" --orient=hor --key=$KEY --tab="Tab 1" --tab="Tab 2" --width=1200 --height=500 --splitter=600 --center
outpt="$?"

[[ $outpt = "1" ]] && exit
[[ $outpt = "0" ]] && mousepad /tmp/testynotes.txt
================================================

both panes load properly, but when I edit the text in the first pane and then click OK, when the /tmp/testynotes.txt file opens, why is it empty?

I tried removing the "&> res1 " part (not knowing what its for) and it didn't help


Thanks,
- Dave

p.s. is there a way to separate out code in this new google groups like you could do before?

dave

unread,
Sep 20, 2020, 11:05:47 PM9/20/20
to yad-common
I ended up solving it by actually adding the copy even though the file without doing this never got over 0 bytes:

...
yad --plug=$KEY --tabnum=1 --text-info --wrap --center --editable --show-uri --back="#456787" --fore=white --always-print-result --window-icon="text-editor" --filename="${FILE}" > /tmp/testynotes.txt &
...
[[ $outpt = "4" ]] && cp /tmp/testynotes.txt "${FILE}"

I guess there's something about the copying that "actualized" the file.     O_o

Also I re-arranged the order of the elements in the yad statement to be more like another instance I have that does already work.
Reply all
Reply to author
Forward
0 new messages