4597 Commits

Author SHA1 Message Date
Colomban Wendling
82f82ed372 Use GLib's portable version gethostname(): g_get_host_name()
Drop our own portability layer and use GLib's one instead (which
actually does exactly the same as our own).

Thanks to Matthew for spotting this.
2013-08-18 00:52:48 +02:00
Igor Shaula
4c3730caf7 LexPowerShell fixes and improvements
* fix here-string highlighting
* add doccomment keyword highlighting
* add #region folding

Closes #132
2013-08-15 19:51:17 -07: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
Matthew Brush
d44dfdb9ac Save configuration when plugin manager dialog is closed
Closes #62
2013-08-15 18:53:21 -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
Nick Treleaven
c615d8431f Don't call getenv twice 2013-08-15 17:52:13 +01:00
exbb2
09e7d8398f Haskell filetype improvements and support for Literal Haskell
Closes #155 and also closes #139
2013-08-14 23:16:39 -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
Nick Treleaven
6d33485337 Fix warning 'comparison between signed and unsigned integer expressions'
With gcc on Windows.
2013-08-11 14:53:35 +01:00
Nick Treleaven
c4f98d85cb Use proper string comparison for portability 2013-08-11 10:57:53 +01:00
elextr
f15f61768d Fix sign comparison warning
Since the previous line ensured len is < 100, just casting it is fine.
2013-08-05 12:13:42 +10:00
Colomban Wendling
458f4f2e75 Don't warn when trying to close a document when none are open
When using the document close keybinding, it is legitimate for the
callback to be called even if there are no documents open, so properly
check for this.

Closes [bugs:#941]
2013-07-21 13:50:25 +02:00
elextr
8d3085b61c Add C++ member pointer operator to scope autocomplete operators
C++ member pointers use the syntax ->* so the scope autocomplete
list was showing after -> then disappearing when * was typed.
Fixes #907 h.
2013-07-18 13:00:06 +10:00
elextr
cac1115ced Prevent reading past start of Scintilla buffer
A quick check seemed to show Scintilla does not check the minimum
value is positive, so just check here to be safe and log message
if it fails.
2013-07-18 12:36:42 +10:00
Colomban Wendling
6e902613b3 Improve some test ordering
Spotted by Daniel Marjamäki, thanks.
2013-07-16 19:13:41 +02:00
Colomban Wendling
b016e132fd Java: Report enums and fix parsing them 2013-07-15 17:42:00 +02:00
Yosef Or Boczko
9ae90f3f87 Fix the my last name and update the my e-mail
Signed-off-by: Frank Lanitz <frank@frank.uvena.de>
2013-07-14 23:41:14 +02:00
Colomban Wendling
d91c532f95 Remove a few dead assignments
Spotted by clang --analyze.
2013-07-13 23:00:43 +02:00
Colomban Wendling
f23b7267cf Fix possible dereference of NULL pointer
Use g_set_error() instead of doing it manually and forgetting to check
whether the pointer is NULL or not before dereferencing it.

Spotted by clang --analyze.
2013-07-13 22:13:07 +02:00
Colomban Wendling
e3fad4a745 Merge branch 'master' into wip/better-php-parser 2013-07-03 19:26:06 +02:00
Colomban Wendling
d1f2005738 Merge branch 'sql-parser-update' 2013-06-26 16:37:12 +02:00
Colomban Wendling
3ba9bd34db SQL: Show variables in the symbol list 2013-06-26 16:33:35 +02:00
Yosef Or Boczko
18bc2d92c1 Fix GTK3 build under Windows 2013-06-25 00:14:37 +02:00
Matthew Brush
79db59d019 Add API docs for search_show_find_in_files_dialog()
This function is used in File Browser plugin and in Tree Browser,
GProject, and GeanyPrj plugins from Geany-Plugins.
2013-06-15 12:45:45 -07:00
Matthew Brush
13ec6ffbea Add new API function plugin_builder_connect_signals() 2013-06-09 15:22:25 -07:00
Colomban Wendling
fe0280037d Indentation width detection: try not to get fooled by comments
C-style multiline comments, used among others in C, C++ and Java, are
often continued on next lines with an additional space followed by an
asterisk:

  1.    /* first comment line
  2.     * continuation line (asterisk is aligned with previous line)
  3.     * last line */

This fools the indentation with detection because lines 2 and 3 from
the above example have an extra space in what is considered being the
line indentation.  In this example, the algorithm would detect an
indentation width of 5 rather than 4, because here most lines have an
indent of 5 -- although they actually have an indent of 4 plus a space
for alignment.  This is not a problem in most situations because there
generally are fewer comment continuation lines than actual code lines
which have a indent multiple of the actual indent width, but with some
code with a lot of comments (e.g. short functions with verbose
documentation comments) this might start to fool the algorithm and
give wrong, annoying, results.

So, try to detect these continuation lines and avoid taking them into
account.
2013-06-02 22:42:47 +02:00
Colomban Wendling
8afff838c1 Improve scrolling to display a plugin's keybindings
When scrolling the keybinding list to display a particular row, which
is used to display a particular plugin's keybindings, consistently
scroll so the row is on the top left.  This makes it easier to see the
row in question since it's always at the same location, and it shows
more child keybindings.
2013-06-01 20:07:12 +02:00
Colomban Wendling
d3b88fb5b1 Fix a leak searching for the keybinding group row 2013-06-01 01:56:31 +02:00
Matthew Brush
44fcdf1b7c Minor tweak to plugin manager button spacing 2013-05-25 17:02:49 -07:00
Pavel Roschin
169a2f4957 Keybindings for plugins 2013-05-25 16:49:06 -07:00
Colomban Wendling
f6e9ac094a Remove use of some of our own deprecated Scintilla wrappers
Remove most obvious calls to our very own deprecated Scintilla wrapper
functions sci_get_text(), sci_get_text_range() and
sci_get_selected_text().

Some calls are still left, but they either really benefit from these
functions or the fix would be more complex.
2013-05-22 04:22:53 +02:00
Colomban Wendling
4bac3717ea Update for new Scintilla styles 2013-05-22 03:38:21 +02:00
Colomban Wendling
72c809f633 Use Glade to create the File Properties dialog 2013-05-20 04:12:44 +02:00
Colomban Wendling
2e9a1753d7 Fix internationalization of the File Properties dialog title 2013-05-20 01:50:02 +02:00
Colomban Wendling
9652a34ef0 Add ellipsis to menu items requiring further user input
This is a very common paradigm used by GNOME, KDE, MacOSX, Windows,
etc., and following it makes our UI more consistent with these and
easier to use by their users.

https://developer.gnome.org/hig-book/stable/menus-design.html.en#menu-item-type-command

Closes #3613494.
2013-05-19 23:15:38 +02:00
elextr
c2d2fddca3 Return a non-printing sequence for no context separators
Function symbols_get_context_separator() returns the symbol
separator for the language, but some languages do not have
symbol context separators, for example markup languages like
Asciidoc.  To prevent the symbols pane wrongly detecting and
acting on a valid character sequence as a separator, return a
non-printing character which should not occur.

Options "" and NULL not used as they break some code and would
need an ABI bump.

Other languages can be added as they are identified.
2013-05-15 14:10:22 +10:00
Colomban Wendling
deede0595e Fix notebook tab switching with keyboard if some pages are hidden
When switching the current notebook tab, we need to take only visible
pages into account.  If we don't and we try switching to an invisible
page, nothing happens.

In practice, the issue is visible on the message window notebook if one
of the tabs are hidden due to one of the "msgwin_*_visible" settings.
2013-05-10 00:10:46 +02:00
Matthew Brush
d9ead8591a Make editor-related View menu items document-sensitive again
They used to be because their parent menu item (Editor) was
document-sensitive but now they are in the top of the View
menu they need to be invdividually made so.

TODO: should they really be/have been document-sensitive? They
can still change the pref without a document open and their
equivalent options in the Preferences dialog are not
document-sensitive? Same goes for existing "Change Font" item.
2013-04-27 11:42:04 -07:00
Colomban Wendling
564ef98f9c Update for new Scintilla styles 2013-04-27 18:30:17 +02:00
Matthew Brush
0f614dd885 Remove reference to removed "menu_view_editor1" (oops) 2013-04-26 23:56:16 -07:00
Matthew Brush
e0245df568 Make "Create" button default for New Project dialog
So it activates when you press the enter/return key in one of the
entries.
2013-04-26 14:56:55 -07:00
Atanas Beloborodov
a3da0467d4 Add version check around deprecated g_thread_init() call.
g_thread_init has been deprecated since GLib version 2.32
2013-04-25 17:30:09 -07:00
Colomban Wendling
ea87576ee4 Remove use of global variables in custom commands code 2013-04-22 20:24:20 +02:00
Colomban Wendling
5868c6991c Fix leaks upon symbol list updating 2013-04-22 20:20:53 +02:00
Colomban Wendling
776c77d6b6 Use GLib version of C99's snprintf() 2013-04-22 20:18:18 +02:00
Colomban Wendling
659276730a Don't use deprecated gtk_icon_set_render_icon() on GTK3 2013-04-22 20:18:18 +02:00
Eugene Arshinov
e8443b19f7 rewrite_reflow: Remove a check inside line breaking implementation that caused breaking to occur too early 2013-04-21 11:45:09 +10:00
Eugene Arshinov
7e732bddc8 rewrite_reflow: Remove no longer used sci_lines_split function that wrapped SCI_LINESSPLIT 2013-04-21 11:45:09 +10:00