Allow symbol auto completion in embedded JavaScript in HTML files (closes #1997409).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2712 ea778897-0a13-0410-b9d1-a72fbfd435f5
This commit is contained in:
parent
7fc218271a
commit
b7802e2693
@ -14,6 +14,9 @@
|
|||||||
* src/editor.c:
|
* src/editor.c:
|
||||||
Improve scrolling on wrapped lines to avoid having search results on
|
Improve scrolling on wrapped lines to avoid having search results on
|
||||||
wrapped lines but outside of visible lines.
|
wrapped lines but outside of visible lines.
|
||||||
|
* src/editor.c:
|
||||||
|
Allow symbol auto completion in embedded JavaScript in HTML files
|
||||||
|
(closes #1997409).
|
||||||
|
|
||||||
|
|
||||||
2008-06-18 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
2008-06-18 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
||||||
|
@ -1231,9 +1231,9 @@ gboolean editor_start_auto_complete(GeanyDocument *doc, gint pos, gboolean force
|
|||||||
root = linebuf + startword;
|
root = linebuf + startword;
|
||||||
rootlen = current - startword;
|
rootlen = current - startword;
|
||||||
|
|
||||||
/* entity autocompletion always in a HTML file, in a PHP file only
|
/* entity autocompletion always in a HTML file except when inside embedded JavaScript,
|
||||||
* when we are outside of <? ?> */
|
* in a PHP file only when we are outside of <? ?> */
|
||||||
if (ft->id == GEANY_FILETYPES_HTML ||
|
if ((ft->id == GEANY_FILETYPES_HTML && (style < SCE_HJ_START || style > SCE_HJ_REGEX)) ||
|
||||||
(ft->id == GEANY_FILETYPES_PHP && (style < SCE_HPHP_DEFAULT || style > SCE_HPHP_OPERATOR) &&
|
(ft->id == GEANY_FILETYPES_PHP && (style < SCE_HPHP_DEFAULT || style > SCE_HPHP_OPERATOR) &&
|
||||||
line != (sci_get_line_count(sci) - 1))) /* this check is a workaround for a Scintilla bug:
|
line != (sci_get_line_count(sci) - 1))) /* this check is a workaround for a Scintilla bug:
|
||||||
* the last line in a PHP gets wrong styling */
|
* the last line in a PHP gets wrong styling */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user