Syntax highlighting for files without extensions

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Mike

Syntax highlighting for files without extensions

Post by Mike »

Is it possible to manually apply a syntax highlighting scheme for files that do not have an extension? As far as I can tell this feature does not exist and I can't enable syntax highlighting for "Default *.*" to simulate it. A pulldown menu in the toolbar listing all syntax highlighting schemes would be wonderful. Until something like that is added, does anyone know of a workaround?
Mike

Re: Syntax highlighting for files without extensions

Post by Mike »

Well, one workaround I've discovered is to rename each file with File -> Rename after I load it into TextPad and do it again before I'm about to save it. But that can be a pain.

I'm submitting this unusual question to the tech support forum because I'm working on a large third-party codebase of Perl modules which, rather inconveniently, have been saved without the standard ".pl" file extension. Unfortunately changing all of the filenames would make the product unusuable so that's not an option.

Thanks in advance for any help.
Mike

Re: Syntax highlighting for files without extensions

Post by Mike »

Shortly after I post a message asking for help I find a solution for my problem. Isn't that always the way it happens?

I just discovered the Document Properties dialog which allows me to manually apply a syntax coloring scheme. A little cumbersome but it does the job.
Andreas

Re: Syntax highlighting for files without extensions

Post by Andreas »

yes, document properties to change temporarily.

to create a document class for files without extensions, use
*.
(make sure that *. is not included in the text document class or any other document class...)
Mike

Re: Syntax highlighting for files without extensions

Post by Mike »

Ah, that did it. I was trying to modify *.* (the default) but I failed to notice that *. was listed under the text category. Thanks a bunch. :)
Charlotte

Re: Syntax highlighting for files without extensions

Post by Charlotte »

I figured out what works for me, you have to Configure -> New Document Class -> then follow the prompts. Make sure EVERYTHING is closed before you do this. Works like a charm now! That was easy...yea sure.
Post Reply