Unicode may have a 2 byte prepended marker
but aside from that there's no spec for anything but character
encoding.
| So, my question : does know if such thing exists for either or
| both notepad and wordpad ?
Definitely not for Notepad. ANSI text is 1 byte per character.
No other data. Unicode may have a 2 byte prepended marker but
aside from that there's no spec for anything but character
encoding.
Mayayana,
| So, my question : does know if such thing exists for either or
| both notepad and wordpad ?
Definitely not for Notepad. ANSI text is 1 byte per character.
No other data. Unicode may have a 2 byte prepended marker but
aside from that there's no spec for anything but character
encoding.
Well, in the case of notepad (ASCII only) I was thinking of something
simpler : maybe a certain specific header line.
To change wordwrap in Notepad you need either 2 mouse clicks or
3 key strokes (<ALT>o<RETURN>. I think, anything else would be
more complicated.
Hello all,
I've got some documents that work best with word-wrapping, and others that work best without. Alas, the wordwrap setting seems to be a global one. Although I could hack something together that would change the associated registry setting before loading a document, but it would be just that, a hack.
I've also tried to google for a way to add it as a commandline argument, but didn't find anything in that regard (if anyone knows about such a setting please do post).
While thinking about wordpad and how it can display RTF documents I realized that there just might be a way to store the above setting in the documents themselves.
So, my question : does know if such thing exists for either or both notepad and wordpad ?
Regards,
Rudy Wieser
There's no feature built in any the applications for that.
But it can be implemented by changing the .txt/.rtf file associations
to run e.g. a VBScript that launches Notepad or Wordpad depending on
the file association.
Hello all,
I've got some documents that work best with word-wrapping, and others that work best without. Alas, the wordwrap setting seems to be a global one. Although I could hack something together that would change the associated registry setting before loading a document, but it would be just that, a hack.
I've also tried to google for a way to add it as a commandline argument, but didn't find anything in that regard (if anyone knows about such a setting please do post).
While thinking about wordpad and how it can display RTF documents I realized that there just might be a way to store the above setting in the documents themselves.
So, my question : does know if such thing exists for either or both notepad and wordpad ?
Regards,
Rudy Wieser
No formatting in a text-only file.
No control codes in the content to regulate formatting.
No file attributes to carry along a linewrap view mode.
You could use Autohotkey to load Notepad to toggle the linewrap
view mode
Linewrap view mode is always on when Notepad loads...
Whatever state was linewrap view mode when you exited Notepad is
the state used when you next load Notepad.
Did you find a registry entry for linewrap view mode in Notepad?
how are you going to trigger which view mode to use when you
load the file into Notepad?
before you call notepad.exe in a batch file to set the wrap
state;
VanguardLH,
No formatting in a text-only file.
I don't quite agree with you there.
I've seen enough textfiles and newsgroup messages with a some formatting. Like "*", "/" and "_" around words and phrases to indicate bold, italic and underscore respecivily.
Also, the textfile could store its formatting in the first or last few
lines. Have you seen Apd's ".LOG" thingy ?
No control codes in the content to regulate formatting.
There are enough ones free/reusable below the space character to
create quite a bit of formatting. Although it would create a
problem for anyone viewing, or worse, editing, such a file with a
plain text editor.
No file attributes to carry along a linewrap view mode.
Depending on the drives storage format (FAT, NTFS, etc) there might be
a few unused ones. I've been thinking of the Archive bit. Not
perfect, but much better than nothing. Also depending on the drives
storage format an Alternate Data Stream (ADS) solution might be used.
You could use Autohotkey to load Notepad to toggle the linewrap
view mode
:-) That jogs memories. Yes, that would be a possibility. if it would be able to see if that entry is checked or not.
Did you find a registry entry for linewrap view mode in Notepad?
Yes. The one you mention a few lines down.
how are you going to trigger which view mode to use when you
load the file into Notepad?
Thats the easy part : I just add another file extension. :-)
I was thinking of the same thing (possibly using another language).
Though this morning I took a peek at notepad, end its quite easy to patch it to either always start in a wordwrap/non-wordwrap mode, or just change where it stores its configuration (a single byte change).
And did you see Apd mention that ".LOG" thingy ? I've found its code and might try to repurpose it ("WRAP").
"R.Wieser" <address@not.available> wrote
| I've seen enough textfiles and newsgroup messages with a some formatting.
| Like "*", "/" and "_" around words and phrases to indicate bold, italic
and
| underscore respecivily.
|
TXT has no formatting. what you're talking about is
symbols that people agree mean something. Look at any TXT in
a hex editor. There is no header. Of course you could make
up your own file type, as a txt file with a header. But you'll
need to program that recognizes it.
And of course the answer is it can't for either based on the basic notepad and the basic text format
the nearest that could be achieved being a batch or similar that
recognised something about the filename, such as a different extension
R.Wieser wrote:
VanguardLH,
No formatting in a text-only file.
I don't quite agree with you there.
I've seen enough textfiles and newsgroup messages with a some formatting.
Like "*", "/" and "_" around words and phrases to indicate bold, italic and >> underscore respecivily.
That's not formatting in the *document*. Those are ASCII characters
that *might* be interpreted by a particular client to accent some
characters. Don't rely on them working in all NNTP clients. They're
just more text.
That's like putting the https://www.intel.com *string* in a message, and
your client happening to parse on the URL string to make it clickable.
It is NOT a hyperlink, like <A>href="<urlstring>">comment</A>. Just
text. Some clients will parse out what looks like URL strings (they
don't always get it right), but don't expect others to be using clients
that will automatically make URL-like strings into clickable objects.[]
The text string is still just text, not a hyperlink.
No control codes in the content to regulate formatting.
There are enough ones free/reusable below the space character to
create quite a bit of formatting. Although it would create a
problem for anyone viewing, or worse, editing, such a file with a
plain text editor.
Don't know what you intended to say there. "Below the space character"?
Are you talking about the ASCII7 charset listed in a table? Those are
still text characters. Some are printable, some are not (in that
printers won't print them, not that don't exist in the file). You can
put NUL characters in a text file, too (and even in filenames and
registry entries which can be difficult for users to handle with text
editors of which regedit.exe is one to display the binary data in the
registry). Some ASCII characters are used to trigger formatting, but
they're still text, like CR (Carriage Return) and Linefeed (LF) which
were originally for teletype printers where CR was to move the printhead
back to the left end of the platen, and LF was to rotate the platen, so
both together were a newline (\n) although Linux only uses CR. Those
ASCII *characters* are not control codes within the document.
Thats the easy part : I just add another file extension. :-)
That would require another filetype association. You didn't mention you >wanted to add another filetype association, but that's doable. Similar
to my suggestion of adding a postfix to the filename, and using the
batch file to decide how to set linewrap view mode in Notepad via the >registry.
I suggested adding a substring to the filename to different when you
want Notepad in linewrap view mode, or not. The problem with a new
filetype is that anyone else viewing the file won't get it opened in >Notedpad, and instead get an error about no associated handler for the
.txtw filetype. I wasn't trying to contrive a setup that would only be >usable to you. If you leave it a .txt extension, anyone can use the
default filetype handler that's the same across all Windows versions
probably back to Windows 286. Having a solution only for your host
means there could be problems later when giving the file to someone
else.
No formatting in a text-only file.
I don't quite agree with you there.
I've seen enough textfiles and newsgroup messages with a some formatting.
Like "*", "/" and "_" around words and phrases to indicate bold, italic
and
underscore respecivily.
That's not formatting in the *document*.
Those are ASCII characters that *might* be interpreted by a particular
client to accent some characters.
Don't rely on them working in all NNTP clients. They're just more text.
Also, the textfile could store its formatting in the first or last few
lines. Have you seen Apd's ".LOG" thingy ?
Doesn't work in all versions of Notepad, so I've never relied on it.
Don't know what you intended to say there. "Below the space
character"? Are you talking about the ASCII7 charset listed
in a table?
...No file attributes to carry along a linewrap view mode.
Guess I should've said file metadata, like EXIF.
Notepad cannot read ADS.
ADS is only available with NTFS.
The Autohotkey script would somehow know what is the state of the
option when Notepad loads. It is a toggle option, so no way to easily
use a key combo to set on and off.
Thats the easy part : I just add another file extension. :-)
That would require another filetype association.
That would require another filetype association. You didn't mention
you wanted to add another filetype association,
I suggested adding a substring to the filename to different when
you want Notepad in linewrap view mode, or not.
I suggested adding a substring to the filename to different when
you want Notepad in linewrap view mode, or not. The problem with
a new filetype is that anyone else viewing the file won't get it
opened in Notedpad, and instead get an error about no associated
handler for the .txtw filetype.
what you're talking about is symbols that people agree
mean something.
Of course you could make up your own file type, as a txt
file with a header. But you'll need to program that recognizes
it.
Look at any TXT in a hex editor. There is no header.
But you'll need to program that recognizes it.
Yes. Plain text. Very clever analysis, Rudy.
It sounds like you have the basics for literacy. :)
But none of those characters means anything *in the context
of the file format*.
If I create an RTF file[snip]
| :-) I'm sure that the next thing you are going to tell me that
| water is wet.
|
Maybe. Do you need me to tell you that?
| The whole thing is that even those "special" files can be read
| and displayed by a non-enhanced plain text editor or viewer.
RTF and HTML? Sure. But they're displayed as plain text.
And age hasn't mellowed you one bit. :)
That sounds to me like your best bet. You can use the MS
style, calling the file extension TXX. Then write yourself
a simple editor that recognizes a header.
VanguardLH,
No formatting in a text-only file.
I don't quite agree with you there.
I've seen enough textfiles and newsgroup messages with a some formatting. >>> Like "*", "/" and "_" around words and phrases to indicate bold, italic
and
underscore respecivily.
That's not formatting in the *document*.
I disagree. Both (can) change the appearance of the text in whatever you
use to view the document with.
Those are ASCII characters that *might* be interpreted by a particular
client to accent some characters.
... or interpreted by the wetware running in a persons brain to get the same effect.
Don't rely on them working in all NNTP clients. They're just more text.
:-) How do you think I became aware of them ? My ancient OE6 just
displays those symbols as they are. Though IIRC I first saw them used in plain textfiles - as a kind of "poor mans" RTF.
Also, the textfile could store its formatting in the first or last few
lines. Have you seen Apd's ".LOG" thingy ?
Doesn't work in all versions of Notepad, so I've never relied on it.
Thats not the point. What is is that even notepad shows you can have "special" behaviour on stuff thats /inside/ the document itself.
Indeed. Keeping it compatible is a good thing to aim for. Thats the nice thing of going thru and than having options : you can pick the one best suited to your needs - whatever they are.
I disagree. Both (can) change the appearance of the text in
whatever you use to view the document with.
Really. Open Notepad, and enter some text.
Okay, it has a feature, but that won't help you in your endeavor
to somehow toggle linewrap view mode other than using Alt+O W.
In addition, you have to pollute the first line to get the
special behavior.
...Indeed. Keeping it compatible is a good thing to aim for.
That's why I think going the file extension route is a bad idea;
In fact, now that I mention adding a context menu entry (that you'd
see in File Explorer when right-clicking on a .txt file), you could
add 2: Open in Notepad (wrap off), and Open in Notepad (wrap on).
Alternatively, I suppose you could define a couple of SendTo entries
to do the same, and I think you mentioned that method.
Although I did mention [SentTo] myself, both will be rather low on my
list of possibilities - as it would mean to make the same choice over-and-over again, instead of just once (and after it just
double-click to open the file).
Personally I'd discard the project and just suffer the
occasional Alt+O W key combo.
I just thought of something: Microsoft has protected some
filetype associations in Windows 10 to prevent malware from
usurping the legitimate handlers for the common filetypes.
Maybe others might jump in with more suggestions on an automatic-
only solution that you'd like, but you might have to wait a bit
longer for them to show up.
While thinking about wordpad and how it can display RTF documents I realized >that there just might be a way to store the above setting in the documents >themselves.
So, my question : does know if such thing exists for either or both notepad >and wordpad ?
So, my question : does know if such thing exists for either or both
notepad and wordpad ?
I don't know about WordPad, but in most editors I've used, both
plain text and RTF, they do wordwrap, and if you don't want it
you press the Enter key and it puts in a CR/LF character.
Steve,
So, my question : does know if such thing exists for either or both >>>notepad and wordpad ?
I don't know about WordPad, but in most editors I've used, both
plain text and RTF, they do wordwrap, and if you don't want it
you press the Enter key and it puts in a CR/LF character.
So do note- and wordpad.
But that means I have to go over all of the text, inserting those /by hand/ >everywhere they are needed.
It also means that that width is fixed, and can't be easily adjusted >depending on the situation (by changing the width of the editors window).
It would also need to be done for every new document that gets generated or
I download which uses such one-line paragraphs.
IOW, wordwrap is handy to have. Just not for /all/ the documents. :-)
Regards,
Rudy Wieser
For that I use XyWrite, an ancient word processor that still
processes words better than the latest ones
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 482 |
Nodes: | 16 (2 / 14) |
Uptime: | 57:11:57 |
Calls: | 9,566 |
Files: | 13,661 |
Messages: | 6,143,085 |