Colomban Wendling
3ec0369f47
Merge branch 'wip/configurable-mime-type--gicon' into wip/configurable-mime-type-gicon
2014-04-14 20:27:20 +02:00
Dimitar Zhekov
20f12872e2
re-fix regex error message parsing (match count returns # of subgroups)
2014-02-15 11:46:23 +11:00
Dimitar Zhekov
df9a1b15c6
fix regex error message parsing (GRegex indexes subgroups, not matches)
2014-02-14 10:08:15 +11:00
Matthew Brush
986c59aecb
Use GeanyFiletypeGroupID enum in a few places
...
Also move the `group_menus` global variable to the top of the file
with the other globals.
2014-01-28 17:16:50 -08:00
Colomban Wendling
6a85a50d21
Replace bare CTags parser ID numbers with an enumeration
...
Avoid using magic numbers in the source for better readability and
easier maintenance.
2014-01-29 01:34:26 +01:00
Matthew Brush
576be4ca3b
Reformat builtin filetype initialization code into tabular format
...
* Add an initialization function ft_init()
* Add a function-like macro to call ft_init() with shorter arguments
* Search and replace old code with FT_INIT() usage
* Layout into columns and add documentation above
2014-01-28 15:32:08 -08:00
Matthew Brush
c674f0660a
Cleanup filetype_make_title() a bit and use it more
...
* Adds TITLE_NONE, TITLE_SCRIPT and TITLE_DOCUMENT.
* Only a few filetype titles were tweaked but we should review the
rest as we could use TITLE_SCRIPT and TITLE_DOCUMENT a lot more
probably.
* Make filetype_make_title() not care about GeanyFiletype type and
return result instead of internally setting ft state.
2014-01-28 15:20:03 -08:00
Colomban Wendling
7473e4b1d9
Add defensive checks for function receiving a GeanyDocument argument
...
Always check the passed-in GeanyDocument argument is a valid one, not
to possibly work on an invalid document.
2014-01-22 17:38:29 +01:00
SiegeLord
828df0ab5f
Add shebang filetype detection for Rust
2014-01-14 12:50:38 -05:00
dobkeratops
b17b4be126
Added the Rust filetype
2014-01-14 12:50:37 -05:00
Colomban Wendling
1f2279aefe
Always use proper functions argument lists
2013-11-10 01:43:10 +01:00
Colomban Wendling
b645eccf6e
Do not ignore keys inside inherited groups
...
When inheriting a group in a filetypes file, do not ignore local keys.
This allows for partial overrides of the parent group, like:
[settings=Parent]
key=value
All keys from Parent's group "settings" would be imported, but now the
"key" key wouldn't be ignored anymore and would override a "key" key
from the group copied from Parent if it exists.
2013-10-15 16:17:59 +02:00
Colomban Wendling
01e7fe4b79
Use GIcon for the filetype icon rather than rendered pixbuf
...
This allows to re-use the icon more easily since it's not rendered at
a particular size but simply an icon description. It also allows for
implicit icon updating when the theme changes if the display code
implements it (and GTK widgets does).
2013-10-15 15:56:44 +02:00
Colomban Wendling
d29b5912ff
Read filetype's mime type from the configuration files
...
This allows custom filetypes to define a mime type, hence the icon
displayed for this filetype; as well as moving ones for built-in
filetypes out of the code to the configuration files.
2013-10-15 03:06:01 +02:00
Igor Shaula
df589a9d52
Add PowerShell filetype
...
Windows PowerShell is a command-line shell and associated scripting language
which comes out of the box with Windows 7/Server 2008/8/Server 2012.
Original lexer from Scintilla is used.
2013-08-15 19:44:33 -07:00
Ypnose
b11a3adb7b
Add detection support for various Shell scripts
...
* Add shebang detection of mksh and tcsh.
* Add file extension detection of mksh, tcsh, and the various
"profile" shell scripts.
Closes #126
2013-08-15 14:48:06 -07:00
Edward Hutchins
01b7191d66
Added hashbang detection for node=>javascript.
...
Closes #149
2013-08-15 13:54:44 -07:00
canou
b518770dea
Add support for DOS, OS/2 and Windows batch files
...
* Uses existing LexOthers.cxx from Scintilla already in use by Geany
* "identifier" style mapping goes to "string" for better presentation
even if it's semantically incorrect, we'll change it back if it causes
issues for anyone.
* Filetype configuration and keywords taken from Don Ho's Notepad++.
Closes #160
2013-08-14 23:04:35 -07:00
Nick Treleaven
0998f1c19c
Make code more readable by renaming poorly named macros NZV and NVL
...
Closes #159
2013-08-14 21:54:20 -07:00
Baptiste Pierrat
d4e61bf093
Add support for Abaqus files
...
Support for Abaqus (.inp) files, including scintilla lexer and tag
parser.
Signed-off-by: Baptiste Pierrat <baptiste.pierrat@gmail.com>
2013-02-12 14:56:38 +01:00
Lex
8294ea2c2e
Add Asciidoc filetype
...
Add a filetype for Asciidoc with symbol parser, but not styling.
2013-01-17 15:43:24 +11:00
Colomban Wendling
d80bc7ce56
Update FSF address
...
Closes #3557875 .
2012-08-24 19:25:57 +02:00
Matthew Brush
e62bec43fc
Use g_build_filename()
instead of g_strconcat()
for paths
2012-08-09 18:21:43 -07:00
Colomban Wendling
1c2c455b1d
Update copyright information
2012-06-18 01:15:04 +02:00
Nick Treleaven
3f7b888b32
Avoid unnecessary hash table for global tag filenames
2012-04-26 13:18:05 +01:00
Nick Treleaven
000bd8547c
Use g_str_has_prefix to prevent invalid memory reads in find_shebang()
2012-04-25 15:47:49 +01:00
Colomban Wendling
6edb38b54a
Rewrite shebang interpreter matching a little
...
Use a generic match code and an array of the mappings for easier code
maintenance.
2012-04-24 21:57:08 +02:00
Nick Treleaven
9426104f0b
Remove utils_build_path() - use g_build_filename instead
2012-02-06 16:41:18 +00:00
Nick Treleaven
e7befb410c
Remove utils_make_filename() - use g_strconcat instead
2012-02-06 16:36:51 +00:00
Nick Treleaven
b287553e4a
Use 'SETPTR' instead of 'setptr'
...
This makes it clearer we're using a macro.
2012-01-25 16:26:16 +00:00
Enrico Tröger
85b5e08c47
Recognize #!/bin/dash as shebang for Shell files ( closes #3470986 )
2012-01-08 13:44:21 +01:00
Nick Treleaven
6c7e709652
Fix memory leak when build regex changes
2011-12-26 17:42:15 +00:00
Nick Treleaven
e503f8262a
Use GRegex for build error regex matching
2011-12-26 17:42:13 +00:00
Colomban Wendling
c69b8eea23
Fix and unify getting open/close/single comment markers
...
Add filetype_get_comment_open_close() to get appropriate start and end
comment markers from a filetype, and use it everywhere these markers
are fetched.
This fixes a crash in editor_insert_multiline_comment() if only single
comments are available (closes #3449635 ).
2011-12-04 00:16:31 +01:00
Lex Trotman
a625955a43
Provide error message for extract regex
...
Print the GError message if the users filetype extract regex does
not compile.
2011-11-14 11:37:32 +11:00
Colomban Wendling
cb72e1d85f
Fix possible crashers in filetypes_detect_from_file_internal()
...
* Never try to do a regex match on a NULL string;
* Don't try to unref a possibly NULL regex.
2011-11-13 20:39:39 +01:00
Colomban Wendling
8942bc810b
Add Objective-C support
...
Based on a patch from Elias Pschernig, thanks.
Parser was taken from upstream CTags.
Closes patch#3325139.
2011-11-13 01:05:24 +01:00
Colomban Wendling
3f31453ace
Fix various integer sign and size issues
2011-11-06 01:12:42 +01:00
Lex Trotman
cdb748c2c4
Add filetype extraction by regex
...
Adds the ability to set filetype on open by extracting it from the
file using a regex on the first few lines (default 2).
2011-10-22 22:55:57 +11:00
Matthew Brush
bd5fba7eb5
Remove extra whitespace at end of lines in all source files.
...
* 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.
2011-10-11 21:52:58 -07:00
Colomban Wendling
d06e9f4575
Remove $Id$ and $Date$ SVN keywords
2011-10-09 22:57:35 +02:00
Nick Treleaven
9522258239
Remove unused and out of sync filetype_remove() - filetypes should not be removed anyway.
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5964 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-09-28 10:47:43 +00:00
Colomban Wendling
d31baeab56
Add missing MIME type to a few filetypes
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5912 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-09-12 23:04:53 +00:00
Colomban Wendling
490867eb4e
Plug a few memory leaks
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5908 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-09-02 21:45:20 +00:00
Colomban Wendling
18388077e6
Add support for filetype-specific indentation settings
...
Closes #3339420 and #3390435 .
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5902 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-08-25 20:14:17 +00:00
Colomban Wendling
4652b74203
Use utils_get_setting() to cleanup filetypes.c:load_settings()
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5896 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-08-25 20:11:25 +00:00
Colomban Wendling
ddb4ad5fa5
Fix some whitespace style errors
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5886 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-08-06 18:34:14 +00:00
Nick Treleaven
b36ebf0a6b
Save filetype build commands straight after editing them instead of
...
at shutdown (patch by Dimitar Zhekov, thanks).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5758 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-05-03 16:08:23 +00:00
Nick Treleaven
418a77b9bd
Revert 'Compiled' filetype group back to 'Programming' (couldn't
...
agree on whether e.g. Java is a compiled language).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5749 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-04-30 15:09:07 +00:00
Nick Treleaven
f0d7c2bd65
YAML *ain't* a markup language (oops).
...
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5748 ea778897-0a13-0410-b9d1-a72fbfd435f5
2011-04-30 11:19:51 +00:00