487 Commits

Author SHA1 Message Date
Thomas Martitz
53a3eff360 Port to the meson build system.
Benefits are blazing fast builds and more user friendly configuration.
This is promised by meson and I would agree in the case of Geany.

Autotools is supported and still the default.

Meson builds might have rough edges but should generally work OK.
Time will tell if it superseeds autotools builds completely.
2022-03-14 22:16:26 +01:00
Thomas Martitz
5e22dfae22 Prepare for meson build system
Autotools-based builds will be supported for some time. This patch makes
some modifications to the Autotools build system necessary to to co-exist
with meson.

- LOCALEDIR and DATADIR won't be defined, replace with GEANY_* where necessary
- VERSION won't be defined, use PACKAGE_VERSION and PACKAGE_STRING instead
- Doxyfile cannot be generated by configure, which wouldn't run in a meson
  build. Generate both Doxyfile and Doxyfile-gi manually using sed
- actual shell script to generate signallist.i (inline shell not a thing in meson)
- path of signallist.i will change, exclude callbacks.c from doxygen
  to make it happy
- geany icon for 24x24 size such that one exists for all sizes
- install license file for Lexilla
- change how tests are run a bit so that runner.sh will also work for meson
- check for dirent.h, required by ctags
2022-03-14 22:08:47 +01:00
Enrico Tröger
55deaab404 Use GDateTime for date and time formatting
This replaces the use of the native strftime() function to use
GLib's GDateTime functions which should work more platform agnostic.

Fixes #2968.
2021-12-01 14:29:43 +01:00
Thomas Martitz
7694aa5acb
Update to Scintilla5 (#2867)
* Update Scintilla to version 5.1.1

A few notes:
- C++17 is required
  Not exactly new since we already imported the latest julia lexer.
- upstream split out lexers into a lexilla library
  We do "comply" by building a separate static library. So in effect, all
  lexers are built-in like before. In the future it may be possible to add
  lexer plugins at runtime.
- Lexer IDs are deprecated in favor of names
  For now we use LexerNameFromID() to map IDs to names but we should
  transition to names soon.
  That being said, the upstream transition seems also not complete.
  There is no name-based version of SCI_GETLEXER, so we're stuck with IDs
  there.

Closes #2824

* Update scintilla_changes.patch

The "which lexers" part is now a separate function that should be less
of a pain when updating to scintilla version that adds lexers.

* Update update-scintilla.sh

You need to extract lexilla sources too now and pass it to the script.
Also the script calls dos2unix for the files, kill that CRLF!
2021-10-10 09:46:37 +10:00
Enrico Tröger
5e9be8324c
SaveActions: Add configurable target directory for instantly saved files (#2769)
Closes #640.
2021-09-19 15:16:06 +02:00
Thomas Martitz
b524a58e12 Merge branch 'gh-codebrainz/remove-gtk2' into master
This merge removes GTK2 support entirely only GTK3 is left.

Closes #2602
2021-05-29 14:17:42 +02:00
Frank Lanitz
2ae3072c1b Update wording at saveactions-plugin
Fixes #2635
2020-11-06 00:25:36 +01:00
Colomban Wendling
aa1cb5c59b Drop use of deprecated GTK2-era GDK key names 2020-11-02 14:52:13 +01:00
Colomban Wendling
d548b72518 Drop use of GTK2 API 2020-11-02 14:52:02 +01:00
Colomban Wendling
9c2b7da3f5 Remove some more GTK2 occurrences and adjust a few comments 2020-11-02 14:45:44 +01:00
Enrico Tröger
1526af4068 Update all copyright notices to mention only the first publish year
And so remove the current year to ease maintenance and since it is not
strictly necessary.
Also remove individual copyright holders (where appropriate) and replace
the name with "The Geany contributors". The detailed authorship
information is still available in the GIT history.

Also remove copyright notice and author names from READMEs.
2019-04-07 11:43:58 +02:00
Colomban Wendling
3fa7576e13 Update Scintilla to version 3.10.0
Scintilla 3.7.6/4.0.0 deprecated `SCE_*STYLEBITS*` and moved it to
deprecated features that require a build-time flag to be available.

Thus, drop use of those (as they are now no-ops anyway) and bump the
ABI (so plugins depending on those don't build mistakenly load) and API
(so a developer can guard use of those if wanted) version accordingly.
2018-08-01 14:51:52 +02:00
Jiří Techet
3e864317ba filebrowser: Don't change directory on project save
This behavior might be unwanted when changing project settings which
is unrelated to project base path and also fixes filebrowser behavior
with the updated way project-save signal is emitted.

The patch also handles the situation where "realized" is called after
project-save is called and overrides file browser's path (which is
something we don't want).
2017-08-04 01:34:23 -07:00
Colomban Wendling
9fa27cb16b splitwindow: Fix document selection popup on GTK >= 3.15.9 && <= 3.21.4
Works around GTK bug https://bugzilla.gnome.org/show_bug.cgi?id=769287.
Stop emission of the ::show-menu signal if it was first emitted from an
inactive toggle button, which happens only in the buggy case.
This workaround tries to not negatively affect a correctly behaving GTK
version in the unlikely case some distributions patched their version.

Fixes #1149.
2016-10-22 15:15:24 +02:00
Matthew Brush
7d172ceeb3 Improve GeanyProxyProbeResults a litte (#1213)
* Add GEANY_ prefix to enumerators.
* Use a discrete set of enumerators so the proxy doesn't have to
  worry about flag bitmasks, which isn't required.
* Update documentation.
* Use the new enumerators in Geany.
* Improve debug output for bogus values a bit.
2016-09-10 19:18:10 -07:00
Jiří Techet
f95656cbe8 Remove makefile.win32 based build system
No more needed using MSYS2.
2016-07-21 13:21:32 +02:00
Jiří Techet
3d2e7d4fca Move TM into src
Move the tag manager implementation to src as it really is part of Geany
sources and start making the ctags directory structure similar to
the universal-ctags one.

In principle, the patch does

mv tagmanager/src src/tagmanager
mv tagmanager/ctags tagmanager/main
mv tagmanager ctags

plus corresponding Makefile.am and configure.ac updates.
2016-07-21 13:08:42 +02:00
Yan Pashkovsky
a5a47da9f2 classbuilder: Use .hpp instead of .h for C++ header file extension
.hpp is a C++-specific extension avoiding any confusion, and better
supported as C++ out of the box by Geany.

Closes #999.
2016-04-30 00:06:51 +02:00
Colomban Wendling
47816339b6 Merge pull request #911 from b4n/deprecations
Deprecations cleanup and improvement
2016-03-01 19:25:53 +01:00
Colomban Wendling
ceca962a4a Merge pull request #547 from techee/locale_utf8
Locale/utf8 fixes
2016-02-28 19:42:34 +01:00
Colomban Wendling
8bce6031b5 Avoid use of deprecated API from core plugins 2016-02-24 23:08:48 +01:00
Thomas Martitz
bbf8e882c2 demoproxy: add a demo proxy showcasing how to create a proxy plugin
This demo proxy does not actually do anything useful. It simply loads
pseudo-plugins from an ini-style file. The point is that there will be a plugin
in the PM dialog for each ini. Each ini-plugin also causes a menu item to be
generated.
2015-10-06 15:40:34 +02:00
Colomban Wendling
280163a244 Merge pull request #469 from kugel-/new_hooks
Plugin loader redesign
2015-08-23 23:50:44 +02:00
Thomas Martitz
58c8144afc plugins: Pass pdata to PluginCallback function by default
If the plugin did not set its own user_data we set it to whatever it set
with geany_plugin_register_full() or geany_plugin_set_data().
This is particularly convinient because PluginCallback is usually statically
allocated, at which point dynamically allocated plugin data doesn't exists yet.
2015-08-23 20:01:41 +02:00
Thomas Martitz
43c58e0fdd plugins: change return codes of geany_load_module() and GeanyPluginFuncs::init
- The return value from geany_load_module is removed (void). It was ignored
  anyway and we have to check separately whether the plugin loaded OK or not
  anyway. If the plugin specific code fails it should simply not call
  geany_plugin_register() (which it should only call iff all other conditions
  are good).

- GeanyPluginFuncs::init() now returns a bool to allow failing initialization.
  Some plugins might want to defer work to their init() (i.e. only do
  it when the plugin was activated by the user), and some of that work can
  possibly fail (e.g. GtkBuilder fails to load .xml).

Note that the GUI integration of the latter is less than ideal but this kind
of GUI/policy work is out of scope for this patch set. Therefore a plugin
failing to init is simply removed from the PM dialog as if it became
incompatible. However, as the code that generates the list does not call init
they will show up again if the PM dialog is re-opened.
2015-08-23 20:01:41 +02:00
Thomas Martitz
8241278472 demoplugin: Adapt demoplugin to the new loader
Demoplugin, while not installed by default, is a nice starting point
and mini-howto. Therefore it should advertise the new loader from the
beginning.
2015-08-23 20:01:41 +02:00
Colomban Wendling
1658babe45 Remove obsolete GTK compatibility code 2015-07-14 15:44:47 +02:00
Colomban Wendling
6c753e591b filebrowser: Use Spawn module to launch the external command
This makes the command syntax consistent with other
Geany ones and more native on Windows.
2015-07-11 22:14:25 +02:00
Colomban Wendling
05f35ed683 Include spawn.h in geanyplugin.h as it has Plugin API bits in it 2015-07-11 22:12:08 +02:00
Jiří Techet
b6f1eb9136 Show tooltip in correct encoding in the file browser
Clearly a typo in the original code.
2015-07-02 18:04:22 +02:00
Thomas Martitz
0b4228b94c win32: change default plugin dir to match Linux.
There is no need to do it differently as Linux here, and it confuses the
autotools based compilation of geany-plugins which installs to libdir/geany
unconditionally.
2015-07-01 23:41:37 +02:00
Colomban Wendling
f427a3a6e1 Merge pull request #455 from techee/filebrowser_icons
Show icons corresponding to MIME types in the file browser plugin
2015-06-18 16:49:37 +02:00
Jiří Techet
358758c9f8 Show icons corresponding to MIME types in the file browser plugin 2015-06-16 15:43:45 +02:00
Jiří Techet
83f261fd64 filebrowser: Add a flag to the tree model to indicate whether en entry is a directory
Used by the subsequent patch which changes "stock-id" to GIcon and
disables row type detection using FILEVIEW_COLUMN_ICON.
2015-04-14 23:49:22 +02:00
Enrico Tröger
a23f4b2d39 Remove deprecated and unnecessary use of GeanyFunctions declaration 2015-04-12 23:11:28 +02:00
Colomban Wendling
f3078ebbc6 Merge branch 'kugel-/linkage-cleanup_rebase-for-merge'
This merges PR#429 with only small history cleanup (no code changes),
and ABI bump.

Closes #355, #358 and #429.
2015-04-10 16:54:30 +02:00
Colomban Wendling
5b9bb1d7b2 Include geanyplugin.h from geanyfunctions.h for compatibility
geanyfunctions.h used to bring all function declarations, and some
plugins depend on this side effect instead of properly including
geanyplugin.h directly.  So, reintroduce the behavior for
compatibility with those plugins.
2015-04-10 16:16:19 +02:00
Colomban Wendling
ede1faca54 Move GeanyFunctions declaration back in plugindata.h
This avoids breaking plugins that don't use geanyplugin.h as they
should but include some random headers.
2015-04-10 16:16:19 +02:00
Thomas Martitz
05f362b3bd Have to include a few more headers for plugins 2015-04-10 16:16:19 +02:00
Colomban Wendling
1cea0b6a79 Merge pull request #411 from techee/shadows
Use consistent shadows across Geany
2015-03-26 22:53:29 +01:00
Jiří Techet
1a36eeaf4d Use consistent shadows across Geany
In principle, any scrolled window should have GTK_SHADOW_IN so the scrollbars
are not above the surface and there is a frame around the scrolled area.

The only exception are the elements of the main window where adding
GTK_SHADOW_IN causes there are too many shadows (or lines in 2D themes)
around the windows and the result isn't nice. So use GTK_SHADOW_NONE
for all main editor scrolled windows. (One additional exception is the
Help->Credits page which is gray and the extra frame doesn't look good.)

Replace frame around VTE with GtkViewport to avoid the extra line around.

Raise the second editor from the splitwindow plugin so it's at the same
level as the main editor.
2015-03-22 15:32:54 +01:00
Colomban Wendling
ae7ecde1df autotools: Fix generating geanyfunctions.h in out-of-tree builds 2015-03-15 15:38:42 +01:00
Colomban Wendling
07aeafab81 autotools: Fix installation directory of plugins on Windows
For some reason we expect the plugins directly inside `$(libdir)` on
Windows instead of `$(libdir)/geany`, so install the plugins there on
Windows.
2015-03-11 02:39:45 +01:00
Matthew Brush
d33758da92 Move Geany's core into a library (libgeany)
This will allow plugins to link against the core when accessing API
functions, now that the macro/struct/funcptr stuff is gone.

Also convert the helper libraries into Libtool helper libraries as
linking a shared library against static libraries is (apparently) not
portable.
2015-03-10 23:09:46 +01:00
Matthew Brush
860df27696 Remove struct/macro/funcptr linkage control for plugin API
Add rest of headers needed for declarations of all public API
functions. Add HAVE_PLUGINS define to geanyplugins.h since some headers
need this and it should always be valid for this header.
geanyfunctions.h left for source-level backwards compatibility for
plugins which might `#include` this header directly. I don't know why
they do it, but some Geany-Plugins do this.
2015-03-10 22:06:47 +01:00
Colomban Wendling
1c1d76721d Fix several tooltips to properly use plain text instead of markup
Most of our tree view tooltips were set from plain text values but
parsed as markup by GTK, which sometimes lead to markup errors, when
the tooltip value contained markup control characters.

This also adds ui_tree_view_set_tooltip_text_column() to the plugin
API so plugins can easily set plain text tooltips from tree views
columns.

Fixes https://sourceforge.net/p/geany/bugs/1091/
2015-02-28 19:15:00 +01:00
Colomban Wendling
e9c9e9a2fa Merge pull request #396 from techee/osx
OS X improvements
2015-02-10 17:12:30 +01:00
Enrico Tröger
7229aa9cff SaveActions: Set file permissions of backup copies to 0600
As discussed in SF bug #125, it might be dangerous to store backup
copies in a publicly accessable directory like /tmp with default
permissions, especially on multi-user systems.
So set the file permissions on non-Windows systems to 0600 by default.
Also improve the documentation of the save Actions plugin to reflect this
change.
2015-01-31 16:11:48 +01:00
Jiří Techet
daecf69c9c Make keybindings_get_modifiers() part of plugin API 2015-01-20 19:33:06 +01:00
Jiří Techet
508216b7b4 Use the open command to open a directory in Finder on OS X 2015-01-20 19:33:06 +01:00