Quote:
|
Any word-processor should cope with RFT. I've just exported a file from Apache OpenOffice in RTF and reloaded it with no problems.
|
Quote:
Dedicated RTF editors don't add all the print layout codes that fullblown word processors do. Once that's in there, you have to find another tool to clean it out if you want to turn the file into, frex, a clean epub (free of weird formatting glitches, and not fighting with your chosen theme). Or do a hand-edit cleanup, which is just loads of fun, tho has made me lots of money. If you want to know how bad the bloat can get -- typically it's 2-3x the original, but I've seen LibreOffice crank a 500k RTF file into over 500mb, because it had made such a hash of its own added formatting. (This wasn't even a complex file; the only complicated part was Track Changes.) |
Quote:
|
Delphi used to have an RTF component, so I wonder what the Open Source cross-platform Lazarus does in that respect...
A quick search suggests there is a port which might be good enough? Quote:
|
Quote:
Not being a programmer (tho at times an interested bystander), I'd forgotten about Lazarus. Seems they win the award for the most cross-platform IDE ever. Thanks for the reminder; I have pascal source for an ancient (1991) DOS program I can't live without, and someday I'd like to see if it can be compiled in a more modern form. |
Didn't mean to suggest it was pre-compiled - you'll need to install Lazarus and compile it to get the executable.
|
Ah, okay, thanks. Been meaning to install Lazarus regardless! (But not today... busy...)
Should I achieve anything worth saving, I'll report back. More likely someone here will beat me to it. :) |
Quote:
I do remember using KWrite over 10 y ago. It handles text highlighting, which is suitable for programmers but you won't be able to freely bold, underline, italicize, change font for each word or line. |
Quote:
Kate understands how to parse and highlight the formatting code in RTF (and a zillion other formats) but it only displays plain text. I have no idea how hard it is to get from there to a WYSIWYG document display, but seems to me a lot of the guts are already there. |
Quote:
Think in terms of low level programming. If you want to render text, there are certain properties that you want to control: 1. The font 2. color 3. bold 4. italic 5. underline Your code would look something like this ChooseFont("Courrier"); setBold(true); renderText_at_position_xy(0, 0, "bla bla bla"); You also need to keep data structures to know when to switch a properties. You also need to know the line spacing needed. You use whatever API has to offer to get the text height. I've writing a similar program to Kate, with text highlighting long ago, for Windows. It was for writing OpenGL shaders. But the guys of WINE have already written a Wordpad. Maybe they should compile a Linux native version. https://appdb.winehq.org/objectManag...rsion&iId=1757 |
Quote:
I wish the source for my fave RTF editor was available (the program is abandoned). |
All times are GMT -5. The time now is 01:36 PM. |