Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

General TRichView support forum. Please post your questions here
Post Reply
Nostradamus
Posts: 67
Joined: Sat May 13, 2006 1:56 pm
Location: Australia

Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by Nostradamus »

Hello,

Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ? Or, can both be done ?
cheers Richard
standay
Posts: 272
Joined: Fri Jun 18, 2021 3:07 pm

Re: Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by standay »

Nostradamus wrote: Tue Dec 07, 2021 9:35 am Hello,

Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ? Or, can both be done ?
cheers Richard
Both can be done and both are fairly easy:

Code: Select all

  Text:
        rvePad.LoadText( FileName, 0, 0, false, TEncoding.UTF8.CodePage );
  RVF:
        rvePad.LoadRVF(FileName);
There are a few more parameters for text. Main thing is the encoding.You can leave that out for ANSI. I always try to use UTF8 so I add in the codepage in mine. You can always load a text file and then save it as RVF.

Stan
Nostradamus
Posts: 67
Joined: Sat May 13, 2006 1:56 pm
Location: Australia

Re: Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by Nostradamus »

I am a beginner at this...
So, if I have two large text files [ source language and target language ]
what is the easiest / best way to open it in the Dual Text Editor ?
standay
Posts: 272
Joined: Fri Jun 18, 2021 3:07 pm

Re: Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by standay »

Nostradamus wrote: Tue Dec 07, 2021 6:51 pm I am a beginner at this...
So, if I have two large text files [ source language and target language ]
what is the easiest / best way to open it in the Dual Text Editor ?
"Dual Text Editor"?? What/where is that?

The "best way" depends on what it is you want to do with the file or files once they are opened. Compare them? Edit them?

If you are working only with plain text files, you may want to use SynEdit or Scintilla. They are designed for plain text use. TRichView is all about formatted text with images, tables and that sort of thing.

It would help if you can explain exactly what it is you are doing or want to do with your files.

Stan
standay
Posts: 272
Joined: Fri Jun 18, 2021 3:07 pm

Re: Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by standay »

Nostradamus wrote: Wed Dec 08, 2021 3:40 am Dual Editor what is that ?

https://www.trichview.com/forums/viewto ... 5f6#p36399
OK, I looked at that. Again, this all depends on what you want to do and what your preferred workflow is. I made UTF8 test text files from your test rvf files. Note that the text files must be in UTF8 for foreign characters. Then I tried loading the rvf files, the text files, and one rvf and one text and it all seems to work in that editor app.

Code: Select all

  RichViewEdit1.LoadRVF(ExtractFilePath(Application.ExeName)+'en.rvf');
  RichViewEdit2.LoadRVF(ExtractFilePath(Application.ExeName)+'ru.rvf');
  
  RichViewEdit1.LoadText(ExtractFilePath(Application.ExeName)+'en.txt',0,-1,false, TEncoding.UTF8.CodePage);
  RichViewEdit2.LoadText(ExtractFilePath(Application.ExeName)+'ru.txt',0,-1,false, TEncoding.UTF8.CodePage);
So, you don't really need to convert the txt to rvf unless you need to for some reason. It all seems to work OK.

Stan
Nostradamus
Posts: 67
Joined: Sat May 13, 2006 1:56 pm
Location: Australia

Re: Which is easier ? Opening a text file in RV Editor or converting txt file to rvf format first ?

Post by Nostradamus »

I FOUND THAT ACTIONS LIST EDITOR DEMO CAN OPEN RTF AND UNICODE TXT FILES..

TUTORIAL /CHECKPOINTS DEMO IS GOOD FOR CHECKPOINTS / BOOKMARK TYPE BEHAVIOUR
Post Reply