Steve Hall | 11 May 2008 02:28

Re: *automatic* syntax hightlighting possible?

On Tue, 2008-05-06 at 15:25 +0200, Ronald Fischer wrote:
>
> I would like to use Cream for editing Perl programs. My programs
> have extension .pl or .pm, and most of the .pl programs have the
> typical #! line in the beginning. "Settings/Syntax Highlighting" in
> Cream is selected.
> 
> When I created a new Perl program and save it, syntax highlighting
> is still not active (i.e. Cream considers it still as a text file),
> so I have to switch it on manually. Opening an existing Perl
> program, however, works - Cream recognizes it as Perl program.
> 
> Is it possible to teach Cream to automatically recognize the syntax
> highlight mode of a new file at the first time the file is saved?

Whew, it took a while to solve this one. Apparently we've had some
minor bugs in the SaveAs routine that was mis-managing buffers in
addition to the minor syntax highlighting issues you saw.

I think I've got it fixed now, everything seems to test out for me on
GNU/Linux and Windows. You can find the updated file here:

http://cream.cvs.sourceforge.net/cream/cream/cream-lib.vim

Just copy it over the file with the same name on your system. Does
that fix what you were seeing?

--

-- 
Steve Hall  [ digitect dancingpaper com ]
:: Cream... usability for Vim
::   http://cream.sourceforge.net

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

Gmane