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

Function IsPyStringStart

scintilla/lexers/LexPython.cxx:47–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45}
46
47static bool IsPyStringStart(int ch, int chNext, int chNext2, literalsAllowed allowed) {
48 if (ch == '\'' || ch == '"')
49 return true;
50 if (IsPyStringTypeChar(ch, allowed)) {
51 if (chNext == '"' || chNext == '\'')
52 return true;
53 if ((chNext == 'r' || chNext == 'R') && (chNext2 == '"' || chNext2 == '\''))
54 return true;
55 }
56 if ((ch == 'r' || ch == 'R') && (chNext == '"' || chNext == '\''))
57 return true;
58
59 return false;
60}
61
62/* Return the state to use for the string starting at i; *nextIndex will be set to the first index following the quote(s) */
63static int GetPyStringState(Accessor &styler, int i, unsigned int *nextIndex, literalsAllowed allowed) {

Callers 1

ColourisePyDocFunction · 0.85

Calls 1

IsPyStringTypeCharFunction · 0.85

Tested by

no test coverage detected