Revision: 3030 http://geany.svn.sourceforge.net/geany/?rev=3030&view=rev Author: ntrel Date: 2008-10-01 17:17:33 +0000 (Wed, 01 Oct 2008)
Log Message: ----------- Fix using common styleset for filetype None.
Modified Paths: -------------- trunk/ChangeLog trunk/src/highlighting.c
Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2008-10-01 16:47:25 UTC (rev 3029) +++ trunk/ChangeLog 2008-10-01 17:17:33 UTC (rev 3030) @@ -3,6 +3,8 @@ * HACKING, doc/Makefile.am: Reformat HACKING as true reStructuredText. Add 'make hacking-doc' target to generate hacking.html. + * src/highlighting.c: + Fix using common styleset for filetype None.
2008-09-30 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
Modified: trunk/src/highlighting.c =================================================================== --- trunk/src/highlighting.c 2008-10-01 16:47:25 UTC (rev 3029) +++ trunk/src/highlighting.c 2008-10-01 17:17:33 UTC (rev 3030) @@ -611,6 +611,8 @@ static void apply_filetype_properties(ScintillaObject *sci, gint lexer, filetype_id ft_id) { + g_assert(ft_id != GEANY_FILETYPES_NONE); + SSM(sci, SCI_SETLEXER, lexer, 0);
SSM(sci, SCI_SETWORDCHARS, 0, (sptr_t) style_sets[ft_id].wordchars); @@ -1906,8 +1908,12 @@
static void styleset_none(ScintillaObject *sci) { + const filetype_id ft_id = GEANY_FILETYPES_NONE; + SSM(sci, SCI_SETLEXER, SCLEX_NULL, 0);
+ styleset_common(sci, ft_id); + set_sci_style(sci, STYLE_DEFAULT, GEANY_FILETYPES_NONE, GCS_DEFAULT);
SSM(sci, SCI_SETWORDCHARS, 0, (sptr_t) common_style_set.wordchars);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.