Commit Graph

776 Commits

Author SHA1 Message Date
Mikkel Kruse Johnsen
9af0176bd2 Updated to 3.22. Need to fix GtkMenu and Popup 2017-01-20 13:10:48 +01:00
Marek Habersack
ccbd9ca6a2 Bind a number of Gtk.CellRendererTextProperties
This binds all the '*-set' properties. The properties are useful when one
wants to restore a previously set property to its initial value. For instance,
when setting the ForegroundRgba property the 'foreground-set' property is
automatically set to 'true' but when we assign 'Gdk.RGBA.Zero' to ForegroundRgba then the
'foreground-set' property is NOT set to false and the foreground becomes black instead
of the default one.
2016-12-18 23:18:54 +01:00
Marek Habersack
2c82d95b58 Fix System.Array usage in {List,Tree}Store
{List,Tree}Store.AppendValues overloads which take System.Array as their
'values' parameter incorrectly pass the array down to SetValues. The latter
expects a 'params object[]' array of parameters but passing an instance of
System.Array to such method will NOT pass the contents of System.Array instance
into the 'params' method as separate members of the parms array. It will instead
box System.Array and the params method will receive one parameter of type
System.Array instead of X parameters of various types. This affects the
following example code:

   var store = new TreeStore (typeof (string), typeof (int));
   store.AppendValues ("One", 1);

If the column configured to retrieve the 'string' value reads data from this
store it will instead get an instance of System.Array and the node displayed by
the TreeView will have no text, won't be clickable etc.

The fix implemented here is to "explode" the System.Array into a separate array
of the 'object[]' type.

The 'TreeStore.AppendValues (params object[] values)' overload no longer calls
the 'TreeStore.Appendvalues (Array values)' overload since the indirection only
wastes time and memory. It now directly calls `SetValues`.
2016-12-18 00:08:05 +01:00
Mikkel Kruse Johnsen
728c1f5aa7 Try to wrap NativeDialog for Windows 2016-07-25 14:40:26 +02:00
grbd
7918531657 Small change to allow for building against latest gtk3 2016-06-30 17:26:16 +01:00
Mikkel Kruse Johnsen
b898323bba Added StyleProviderPriority 2016-06-08 14:39:17 +02:00
Mikkel Kruse Johnsen
7236eb3fa7 Upstream patches 2016-06-08 08:56:55 +02:00
Mikkel Kruse Johnsen
8134f48a5a Generate 'rgba' property 2016-05-17 10:51:59 +02:00
Mikkel Kruse Johnsen
110b73dbb7 Generate GdkColor properties 2016-05-17 09:23:03 +02:00
Mikkel Kruse Johnsen
c1daeff0eb Made alias Symbol GdkRgba to GdkRGBA. This will provide properties of the type GdkRGBA in Gtk. 2016-05-17 08:59:19 +02:00
Mikkel Kruse Johnsen
36b6b713e6 Updated to Gtk+ 3.20.4 2016-05-11 09:50:01 +02:00
cra0zy
5e75d001c8 Fix Dialog creation 2016-05-06 10:15:22 +02:00
MIkkel Kruse Johnsen
28ba4876e3 Merge pull request #3 from orion75/gtk-sharp-3-14-branch
gtk: Fix return types for null_term_array* methods in AboutDialog
2015-12-02 10:40:51 +01:00
Mikkel Kruse Johnsen
2c5ba65fa7 Updated to gtk+ 3.18.5 2015-12-02 09:20:44 +01:00
Mikkel Kruse Johnsen
a8d9a119d8 Update to Gtk 3.18.2
Had to change gapi2xml.pl to use the new properties method/macro in gtkwindow.c
- Issue, "invisible-chars" and "inner-border" is generated twice in gtkentry.c

Made patch to gwin32registrykey to use little endian by default. So Windows om ARM may fail.
2015-11-10 11:37:34 +01:00
Harol Alfonso Reina
4c65e70975 gtk: Fix return types for null_term_array* methods in AboutDialog
this corrects the properties Authors, Artists and Documenters
2015-11-06 13:46:10 -05:00
MIkkel Kruse Johnsen
62b9345c7f Merge pull request #2 from orion75/gtk-sharp-3-14-branch
Gtk sharp 3 14 branch
2015-10-30 08:23:19 +01:00
Harol Alfonso Reina
c2fd7af4b4 Changed type of property BackgroundGdk in gtk-api.raw 2015-10-29 12:28:34 -05:00
Harol Alfonso Reina Herrera
b20872aa41 Revert: Seperate pkgconfig version from package version 2015-10-29 11:43:03 -05:00
Harol Alfonso Reina Herrera
751a5ceed5 Update References file's in csproj 2015-10-29 10:10:23 -05:00
Harol Alfonso Reina Herrera
16310b15a0 Update csproj TargetFrameworkVersion 2015-10-29 09:24:44 -05:00
Antonius Riha
d98f6c3421 csproj ToolsVersion to 4.0 2015-10-29 08:48:49 -05:00
Mikkel Kruse Johnsen
e1cba4116a Rename RowActivated to ListRowActivated for ListBox 2015-09-04 12:08:06 +02:00
Mikkel Kruse Johnsen
95f59a7b5a Fix IScrollable and List class 2015-09-04 11:54:19 +02:00
Mikkel Kruse Johnsen
6774f0b71d Track 3.16.6 2015-09-04 11:15:29 +02:00
nyx
eb227d8598 Removed CssProvider reference to unavailable interface GtkStyleProviderPrivate 2015-07-23 23:40:17 +03:00
Mikkel Kruse Johnsen
8bf4dc10d9 3.14.6 2015-01-20 10:26:02 +01:00
Mikkel Kruse Johnsen
4efdb7c3aa Seperate pkgconfig version from package version 2014-11-05 15:06:03 +01:00
Mikkel Kruse Johnsen
d445b4943e Fix conditional in Makefile.am 2014-11-05 08:59:19 +01:00
Mikkel Kruse Johnsen
4c4e2a8754 Remove utf8 variant. Not used anymore on windows 2014-11-05 08:49:52 +01:00
Mikkel Kruse Johnsen
c851bdc837 Ignore gui-thread-check on windows 2014-11-05 08:49:09 +01:00
Mikkel Kruse Johnsen
2baa86a03e Include cairo in gapi 2014-11-03 16:11:39 +01:00
Mikkel Kruse Johnsen
d33628d632 Updated to Gtk 3.12 2014-11-03 15:52:55 +01:00
Antonius Riha
b75e7c82b6 gtk: Fix Builder xml definition loading
Gtk.Builder crashes when AddFromString(string) is called with a string
that contains a BOM. Hence, if the buffer contains a BOM, just skip it.

This fixes the crash with the Gtk# 3 project template in MonoDevelop
(robpvn/MonoDevelopGtkSharp3Template).
2014-09-21 15:49:10 +02:00
Antonius Riha
a281a85f9d gtk: Use the same behavior in Builder constructor overloads
Each overload needs to call Assembly.GetCallingAssembly () explicitly,
otherwise the calling assembly would end up being gtk-sharp.
2014-09-21 15:45:00 +02:00
Antonius Riha
2034648ec2 csproj: Fix assembly names and include *.dll.config in output
Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
2014-09-21 15:07:38 +02:00
Marcin Kolny
dee590926a build: Add a pkg-config file for gdk-sharp-3.0
This allows consumers to specifically require gdk-sharp-3.0 without
having to pull in the full gtk-sharp-3.0.

Closes issue #101.

Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
2014-04-21 21:36:57 +02:00
Gankov Andrey
1da92bdd62 gtk: Add ListStore.SetValue overload for long type
Without that change, using ListStore.SetValue with a long would use the
float overload, which might not be expected and cause some issues.

Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
2014-04-21 16:50:21 +02:00
Stephan Sundermann
a74534e835 generator: Create a directory for each namespace
When dealing with several namespaces there might be classes with the same name
(especially Global which is autogenerated in g-i based bindings). On generation
the file would be overriden by the last occurence in the xml. To encounter
this every namespace has it's own directory now. This also improves structure
a lot when dealing with big libraries.

Also do the necessary adaption for the build and the csproj files.
2014-03-01 21:16:54 +01:00
Bertrand Lorentz
49295c119b build: Only build gui-thread-check profiler module on mono
The profiler module will only work with mono, so we don't need to build
it on Windows with the .Net framework.
2014-02-23 16:18:28 +01:00
Bertrand Lorentz
691de4e606 gtk: Fix dll name and use a const for all DllImports in custom code
In Windows builds of GTK+ 3.x, the dll filename is libgtk-3-0.dll.

We use this opportunity to use a common const in the DllImport
statement for all custom code.
2014-02-23 15:12:20 +01:00
Bertrand Lorentz
32d10bd319 Use GLib.Marshaller.Free instead of calling g_free directly
Using the GLib.Marshaller.Free method means we don't need to have the
g_free function definition duplicated all over the place.
2013-11-17 16:20:02 +01:00
Bertrand Lorentz
d6f06860fb Merge pull request #90 from knocte/embedded
gtk: fix Application to be more robust when embedding mono
2013-11-09 08:10:06 -08:00
Andrés G. Aragoneses
2967482762 Revert "gtk: Mark the Cairo.Context in Widget.Drawn as owned"
This reverts commit 21bfaa7a9d.

After fixing the memory leak when finalizing a Context object in the
previous commit, native crashes would happen when using a Gtk#-based
app. The reason is that this commit tried to fix the leak with the wrong
approach of marking the CairoContext as owned. This avoided the leak by
not incrementing the reference count, but now that the leak is fixed,
cairo_destroy is called one time too much.

The CairoContext passed in the Draw signal is not marked as
transfer-ownership=full in GObject-Introspection metadata. So unmarking
this as owned fixes the "potential double-free" assertion that was
causing the crash.
2013-11-03 17:01:34 +01:00
Andrés G. Aragoneses
53e884dd22 gtk: fix Application to be more robust when embedding mono
When embedding mono, Environment.GetCommandLineArgs() would not return
an array with any element.

Reported in the mailing list, by Vardar Sahin.
2013-11-03 16:11:42 +01:00
Bertrand Lorentz
fc9746013d gtk: Fix TreeView.GetTooltipContext method signature (bxc#14678)
The x and y parameters of gtk_tree_view_get_tooltip_context() are marked
as inout in the Gtk+ docs, so we need to mark them as ref.
2013-11-03 14:42:39 +01:00
Andrés G. Aragoneses
10546e2ffa MSBuild: fix the solution build (except audit and sample projects)
This commit makes it possible to build any project of the gtk-sharp.sln
from an IDE (except audit and sample projects, which require a bit more
work).

This doesn't mean that autotools is deprecated, but just that it is more
comfortable to use an IDE when working on gtk-sharp because it will
offer better auto-completion, and will stop highlight misleading
semantic errors, from now on.
2013-11-02 15:48:58 +01:00
Andrés G. Aragoneses
7dafb39c01 gui-thread-check: add two more methods to the whitelist
At application shutdown, it's very likely to be spammed by
gui-thread-check with a river of:

*** GTK CALL NOT IN GUI THREAD: Widget.Dispose
*** GTK CALL NOT IN GUI THREAD: Widget.remove_InternalDestroyed
*** GTK CALL NOT IN GUI THREAD: Widget.Dispose
*** GTK CALL NOT IN GUI THREAD: Widget.remove_InternalDestroyed
...

From what I gather, these two methods (in gtk-sharp master[1]) could
be called by the finalizers, but do not call any unmanaged functions,
so it should be ok to not report them as violations.

[1] https://github.com/mono/gtk-sharp/blob/master/gtk/Widget.cs

Cherry-picked from 77a40599ca
2013-10-31 10:18:02 +01:00
Andrés G. Aragoneses
dcc2850a39 gui-thread-check: use fflush() after printf()
Using fflush() right away after printf() calls avoids the buffers to
be written in an apparently complete-out-of-sync way from the point
of view of the developer. This problem would specially occur when
redirecting all output to a file this way:

  mono Foo.exe > out.txt 2>&1

Without this fix, all the output from gui-thread-check would appear
at the end of the file, instead of in between the output generated by
the program.

Cherry-picked from 6988cd4cd2
2013-10-28 21:57:29 +01:00
Andrés G. Aragoneses
5ce4e63bd9 gtk: reference Cairo in MSBuild csproj 2013-10-22 12:33:24 +02:00