MCPcopy Create free account
hub / github.com/ProgerXP/Notepad2e / StateForScript

Function StateForScript

scintilla/lexers/LexHTML.cxx:420–446  ·  view source on GitHub ↗

Return the first state to reach when entering a scripting language

Source from the content-addressed store, hash-verified

418
419// Return the first state to reach when entering a scripting language
420static int StateForScript(script_type scriptLanguage) {
421 int Result;
422 switch (scriptLanguage) {
423 case eScriptVBS:
424 Result = SCE_HB_START;
425 break;
426 case eScriptPython:
427 Result = SCE_HP_START;
428 break;
429 case eScriptPHP:
430 Result = SCE_HPHP_DEFAULT;
431 break;
432 case eScriptXML:
433 Result = SCE_H_TAGUNKNOWN;
434 break;
435 case eScriptSGML:
436 Result = SCE_H_SGML_DEFAULT;
437 break;
438 case eScriptComment:
439 Result = SCE_H_COMMENT;
440 break;
441 default :
442 Result = SCE_HJ_START;
443 break;
444 }
445 return Result;
446}
447
448static inline bool issgmlwordchar(int ch) {
449 return !isascii(ch) ||

Callers 1

ColouriseHyperTextDocFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected