Remove type keywords caching function since it doesn't really speed up
anything and we don't care if the keywords change since they can/should
still be reloaded. This also prevents "leaking" a static GString once
when the application closes and saves a call to g_string_free() when the
type keywords have changed.
Rename document_update_highlighting() to document_update_type_keywords()
since no re-highlighting is needed when updating Scintilla keywords.
Scintilla highlights the new keywords automatically so this saves a call
to queue_colourise().
Remove update_type_keywords() function since this is now all handled
in the document_update_type_keywords() function. This function had a
comment about updating all documents when sci is NULL but it was never
used in this way since it was only called on document_load_config() which
always operates on a single document and the sci should not be NULL.
These leaks actually were not "real" leaks since the memory will anyway
be kept until quit. Fixing those only makes the code "cleaner" and
will prevent them to "hide" some other (real) ones at debug times.
The format of the error message output of the py_compile module has changed in
Python 2.6. The code now tries to detect the format and parse it accordingly.
Store a pointer to the stash pref for each row, so display/update is just
O(n) instead of O(n^2) time.
This changes the order prefs are updated in, but this doesn't matter.
This helps when trying to run build commands that don't exist;
the status bar message for that is now:
Process failed (The system cannot find the file specified.)
When using the commenting features (ex. toggle line commentation),
detect the the type of comments for the filetype of the line with
the caret rather than using the filetype of the current document.
Filetype is determined by the Scintilla state/style at the
beginning of the line where the caret is.
This does not fix the existing bug where using the commenting
features on lines with things like `<script>` will result in an
HTML-style comment to be wrapped around it and also where using
the commenting feature on a line with something like `<?php`
will not only wrap it in an HTML-style comment but it also won't
be able to uncomment the line.
This closes bug ID 2863829[1] and 3127598[2].
[1] https://sourceforge.net/tracker/?func=detail&aid=2863829&group_id=153444&atid=787791
[2] https://sourceforge.net/tracker/?func=detail&aid=3127598&group_id=153444&atid=787791
* Processed with rstrip-whitespace.py script added to scripts/ directory.
* Script run on all .c and .h files in src/ and plugins/ directories.
* Also remove more than one newline at the end of files.
This reverts commits fbf77f586d65e319ecc1da11e98dcd932dd88b28 and
3816e40190c2f5331992f795f297669a399803fb.
While having the .rst extension helps GitHub formatting the file, the
renaming broke both Autotools and Waf build systems.
Automake requires README to exist by default, but it was renamed to
README.rst recently. Thus, change Automake strictness to `foreign'
for README to be optional, and distribute README.rst explicitly.
Although `foreign' strictness don't require any of the README, INSTALL,
COPYING, etc. files, it still includes them if available, so the
distribution still includes them.