Document Type for "View Source" ?

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, MudGuard

Post Reply
mo
Posts: 306
Joined: Tue Mar 11, 2003 1:40 am

Document Type for "View Source" ?

Post by mo »

Just making trouble here. Does anyone have an idea how to set up syntax highlighting for the files that come up when you "view source" on an .html page?

I don't see a document extension for these files.
Best Wishes!
Mike Olds
User avatar
s_reynisson
Posts: 939
Joined: Tue May 06, 2003 1:59 pm

Post by s_reynisson »

I just got rid of text.syn under
Configure -> Preferences -> Document Classes -> Text.
Now I'm using html.syn there so when I have a document
without an extension, like in view source from IE, I'm getting
the syntax colors. Besides, all text.syn did for me was to
highlight URL's and html.syn takes care of that 8)
mo
Posts: 306
Joined: Tue Mar 11, 2003 1:40 am

Post by mo »

s_r,

Thanks for the response, but no luck for me. It works on .txt files ok, and I will keep it for that, but it doesn't do anything for the i.e. view source file that comes up...and default doesn't seem to allow syntax highlighting.
Best Wishes!
Mike Olds
User avatar
bbadmin
Site Admin
Posts: 1038
Joined: Mon Feb 17, 2003 8:54 pm
Contact:

Post by bbadmin »

The View Source command in IE creates a temporary file, without a file extension. Therefore, you need to add "*." to the list of members of the HTML document class to get them to be highlighted. If that is already a member of another document class, you'll need to delete it from that class.

Keith MacDonald
Helios Software Solutions
User avatar
MudGuard
Posts: 1295
Joined: Sun Mar 02, 2003 10:15 pm
Location: Munich, Germany
Contact:

Post by MudGuard »

With all the Internet Explorers I know the temp file has
[1]
(or some other number) at the end of the file name.

*].
is working as well and does not catch Unix shell scripts - just make sure no document class with the more general *. is below the html document class (by renaming if necessary)
mo
Posts: 306
Joined: Tue Mar 11, 2003 1:40 am

Post by mo »

Thanks for the responses, MudGuard and admin. I went with adding *]. to the files for the TEXT document class and it seems to be working fine.

OT: I see what they are talking about when they say that EMACS is becoming an operating system. I begin to see everything through TextPad.
Best Wishes!
Mike Olds
Post Reply