Another enhancement to HFCL WordScribe and WordWriter

HMG Unicode versions 3.1.x related

Moderator: Rathinagiri

User avatar
kcarmody
Posts: 119
Joined: Tue Oct 07, 2014 11:13 am
Has thanked: 5 times
Been thanked: 11 times
Contact:

Another enhancement to HFCL WordScribe and WordWriter

Post by kcarmody » Mon Jun 20, 2016 1:14 am

I have made one more enhancement to the WordScribe and WordWriter HFCL applications that I submitted three weeks ago. For this one, I added some hot key commands to INCLUDE\i_keybd.ch, and then I used two of them in WordScribe and WordWriter.

You can download the updated proposal from my site as follows. It should be installed on top of 3.4.3.
Hope you enjoy!

Kevin

User avatar
Rathinagiri
Posts: 5162
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 128 times
Been thanked: 130 times
Contact:

Post by Rathinagiri » Mon Jun 20, 2016 1:22 am

Thank you Kevin.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

User avatar
Rathinagiri
Posts: 5162
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 128 times
Been thanked: 130 times
Contact:

Post by Rathinagiri » Mon Jun 20, 2016 1:25 am

Kevin,

I wanted to create rtf files from inside the program. Is it possible? If it is, we can create report files in rtf.

Especially we have to create tables.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

User avatar
Steed
Posts: 292
Joined: Sat Dec 12, 2009 3:40 pm
Been thanked: 2 times
Birthday

Post by Steed » Mon Jun 20, 2016 2:58 am

GRACIAS

User avatar
serge_girard
Posts: 1838
Joined: Sun Nov 25, 2012 2:44 pm
DBs Used: 1 MySQL - MariaDB
2 DBF
Location: Belgium
Has thanked: 278 times
Been thanked: 63 times
Contact:

Post by serge_girard » Mon Jun 20, 2016 7:02 am

I wanted to create rtf files from inside the program
This would be great !

Serge

User avatar
kcarmody
Posts: 119
Joined: Tue Oct 07, 2014 11:13 am
Has thanked: 5 times
Been thanked: 11 times
Contact:

Post by kcarmody » Mon Jun 20, 2016 11:49 am

Rathinagiri wrote:I wanted to create rtf files from inside the program. Is it possible? If it is, we can create report files in rtf.

Especially we have to create tables.
WordScribe and WordWriter are word processors and can write to RTF files as well as several formats of TXT files. They do this through the EX...SAVEFILE method of a rich edit control, which sends a Windows message to write the rich edit control to the file. This message can only be used on rich edit controls.

If you had a text buffer and wanted to write it to RTF, you could define an invisible rich edit box, write the buffer to a temporary text file, use the EX...LOADFILE method to read the temp file, then use EX...SAVEFILE to write it to an RTF file. But you would not have any formatting other than tabs and line breaks, so I don't see what the advantage of this would be. Tabs would be the only way to format table data, since rich edit controls cannot create tabs but not tables. Tabs are not a very good way to format table data.

An RTF file is just a series of text based commands, however, so it is not very hard for you to write functions that output RTF commands into an RTF file. I did this once to generate an RTF table in one of my applications, Akshara Bridge (http://kevincarmody.com/software/aksharabridge.html). This program transliterates between various Indian scripts, and when it encounters errors in the input, it can generate an error file. If you select an error file name ending in .rtf, it generates an RTF table for each error. You can download the source and look at ErrorChar() in AksharaBridgeBack.prg. I've attached a zip file containing a sample RTF file generated by this function.

Hope this helps.
Kevin
Attachments
TestErrDevErr.zip
(1.32 KiB) Downloaded 56 times

User avatar
Rathinagiri
Posts: 5162
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 128 times
Been thanked: 130 times
Contact:

Post by Rathinagiri » Mon Jun 20, 2016 11:55 am

Wonderful. Thank you Kevin.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

User avatar
kcarmody
Posts: 119
Joined: Tue Oct 07, 2014 11:13 am
Has thanked: 5 times
Been thanked: 11 times
Contact:

Post by kcarmody » Mon Jun 20, 2016 12:12 pm

Another alternative is to write HTML tables. HTML syntax is much easier than RTF, and more flexible too. For example, table columns in RTF are fixed width, but variable width in HTML.

User avatar
Rathinagiri
Posts: 5162
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 128 times
Been thanked: 130 times
Contact:

Post by Rathinagiri » Mon Jun 20, 2016 1:52 pm

That is right. I have already made that and shared here.

viewtopic.php?f=9&t=4603
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

User avatar
kcarmody
Posts: 119
Joined: Tue Oct 07, 2014 11:13 am
Has thanked: 5 times
Been thanked: 11 times
Contact:

Post by kcarmody » Wed Jun 22, 2016 3:43 pm

I've just updated one of the hot key demos to reflect the new hot key commands in INCLUDE\i_keybd.ch.
Kevin

Post Reply