SSTE (Super Simple Text Editor)

versatile 64-bit multi-user Linux distribution


Moderators: kirk, jamesbond, p310don, JakeSFR, step, Forum moderators

User avatar
stemsee
Posts: 830
Joined: Sun Jul 26, 2020 8:11 am
Location: lattitude 8
Has thanked: 195 times
Been thanked: 142 times
Contact:

Re: SSTE (Super Simple Text Editor)

Post by stemsee »

For the Markup function I will add format presets along the header of the document preview. These can be coppied to any part of the document to allow the user to edit with formatting. This means there will be a limited number of presets. However these can be defined by the user in markup options. The initial formatting will be saved in /root/sste/text and the text will be piped back into the main SSTE text editor for saving and for printing. While the user can also take a screenshot of the formatted text preview to print as an image or pdf (raw).

sstex-20250318T085915.png
sstex-20250318T085915.png (61.51 KiB) Viewed 59 times

Edit: Ooh! I just had an idea ... explains the headache! :lol: ... the pango markup formatting is hidden from view in the preview, but in the main text editor it can be viewed and edited, then for re-combining markup and text, which get separated on save, the text for each different formatting section can be simply stored in a variable, $A $B $C $D $F $G $H .... etc and recombined on opening. Where $A='title' is underlined large bold text as in 'title', $B='body of text', etc. Formatting can also be stored in variables,

Code: Select all

TITLESPAN='<span font=\"$tfont\" fgcolor=\"$tfcol\" bgcolor=\"$tbcol\">'
BODYSPAN='<span font=\"$bodfont\" fgcolor=\"$bodfcol\" bgcolor=\"$bodbcol\">'
SMALLITALICSPAN='<span font=\"$sifont\" fgcolor=\"$sifcol\" bgcolor=\"$sibcol\">'
ENDSPAN='</span>'

"${TITLESPAN}${A}${ENDSPAN}"
"${BODYSPAN}${B}${ENDSPAN}"
Post Reply

Return to “FatDog64”