java-gnome-developer Mailing List for The java-gnome language bindings project (Page 7)
Brought to you by:
afcowie
You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(37) |
Dec
(14) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(2) |
Feb
(20) |
Mar
(20) |
Apr
(8) |
May
|
Jun
(1) |
Jul
(6) |
Aug
(39) |
Sep
(37) |
Oct
(34) |
Nov
(50) |
Dec
(22) |
2002 |
Jan
(7) |
Feb
(13) |
Mar
(32) |
Apr
(16) |
May
(26) |
Jun
(20) |
Jul
(32) |
Aug
(7) |
Sep
(2) |
Oct
(11) |
Nov
(3) |
Dec
(35) |
2003 |
Jan
(11) |
Feb
(3) |
Mar
(8) |
Apr
(3) |
May
(11) |
Jun
(20) |
Jul
(11) |
Aug
(29) |
Sep
(13) |
Oct
(91) |
Nov
(185) |
Dec
(207) |
2004 |
Jan
(108) |
Feb
(171) |
Mar
(207) |
Apr
(113) |
May
(22) |
Jun
(53) |
Jul
(69) |
Aug
(43) |
Sep
(34) |
Oct
(182) |
Nov
(101) |
Dec
(61) |
2005 |
Jan
(86) |
Feb
(45) |
Mar
(106) |
Apr
(67) |
May
(70) |
Jun
(47) |
Jul
(19) |
Aug
(34) |
Sep
(24) |
Oct
(45) |
Nov
(20) |
Dec
(58) |
2006 |
Jan
(21) |
Feb
(21) |
Mar
(16) |
Apr
(24) |
May
(24) |
Jun
(47) |
Jul
(20) |
Aug
(8) |
Sep
(13) |
Oct
(7) |
Nov
(23) |
Dec
(2) |
2007 |
Jan
|
Feb
(14) |
Mar
(3) |
Apr
(11) |
May
(1) |
Jun
(15) |
Jul
(2) |
Aug
(5) |
Sep
(10) |
Oct
(5) |
Nov
(1) |
Dec
|
2008 |
Jan
|
Feb
(13) |
Mar
(13) |
Apr
(4) |
May
(2) |
Jun
(1) |
Jul
(5) |
Aug
(7) |
Sep
(2) |
Oct
(14) |
Nov
(11) |
Dec
(12) |
2009 |
Jan
(30) |
Feb
(4) |
Mar
(16) |
Apr
(9) |
May
(9) |
Jun
(7) |
Jul
(6) |
Aug
(3) |
Sep
(14) |
Oct
(8) |
Nov
(12) |
Dec
(9) |
2010 |
Jan
(4) |
Feb
(27) |
Mar
(6) |
Apr
(4) |
May
(3) |
Jun
(13) |
Jul
(6) |
Aug
(15) |
Sep
(15) |
Oct
(12) |
Nov
(11) |
Dec
(9) |
2011 |
Jan
(12) |
Feb
(11) |
Mar
|
Apr
(3) |
May
|
Jun
(3) |
Jul
(1) |
Aug
|
Sep
(1) |
Oct
(8) |
Nov
(1) |
Dec
|
2012 |
Jan
|
Feb
(10) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(6) |
Aug
(2) |
Sep
(7) |
Oct
(7) |
Nov
|
Dec
(4) |
2013 |
Jan
(8) |
Feb
(1) |
Mar
(1) |
Apr
(2) |
May
(3) |
Jun
(3) |
Jul
(16) |
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(1) |
2014 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
2016 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2018 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: bob <loi...@pa...> - 2010-10-20 14:35:15
|
When I'm reading the banshee source (C# language), I found how to create a custom component in C#. It's very simple, the developer had to extend the Gtk.Bin Object. I search to do the same thing in Java but I don't found any "simple" solution, we couldn't extends the Bin object. I think it is possible to create this component in C and create binding like all object in java-gnome but it's not very simple (add C code and add Java binding working with java-gnome). There is a solution to create a custom widget in Java ? Could you update the java-gnome library to do it ? // // The custom GTK widget RoundedFrame // namespace Hyena.Widgets { public class RoundedFrame : Bin { private Theme theme; protected Theme Theme { get { return theme; } } private Widget child; private Gdk.Rectangle child_allocation; private bool fill_color_set; private Cairo.Color fill_color; private bool draw_border = true; private Pattern fill_pattern; private int frame_width; // Ugh, this is to avoid the GLib.MissingIntPtrCtorException seen by some; BGO #552169 protected RoundedFrame (IntPtr ptr) : base (ptr) { } public RoundedFrame () { } public void SetFillColor (Cairo.Color color) { fill_color = color; fill_color_set = true; QueueDraw (); } public void UnsetFillColor () { fill_color_set = false; QueueDraw (); } public Pattern FillPattern { get { return fill_pattern; } set { fill_pattern = value; QueueDraw (); } } public bool DrawBorder { get { return draw_border; } set { draw_border = value; QueueDraw (); } } #region Gtk.Widget Overrides protected override void OnStyleSet (Style previous_style) { base.OnStyleSet (previous_style); theme = Hyena.Gui.Theming.ThemeEngine.CreateTheme (this); frame_width = (int)theme.Context.Radius + 1; } protected override void OnSizeRequested (ref Requisition requisition) { if (child != null && child.Visible) { // Add the child's width/height Requisition child_requisition = child.SizeRequest (); requisition.Width = Math.Max (0, child_requisition.Width); requisition.Height = child_requisition.Height; } else { requisition.Width = 0; requisition.Height = 0; } // Add the frame border requisition.Width += ((int)BorderWidth + frame_width) * 2; requisition.Height += ((int)BorderWidth + frame_width) * 2; } protected override void OnSizeAllocated (Gdk.Rectangle allocation) { base.OnSizeAllocated (allocation); child_allocation = new Gdk.Rectangle (); if (child == null || !child.Visible) { return; } child_allocation.X = (int)BorderWidth + frame_width; child_allocation.Y = (int)BorderWidth + frame_width; child_allocation.Width = (int)Math.Max (1, Allocation.Width - child_allocation.X * 2); child_allocation.Height = (int)Math.Max (1, Allocation.Height - child_allocation.Y - (int)BorderWidth - frame_width); child_allocation.X += Allocation.X; child_allocation.Y += Allocation.Y; child.SizeAllocate (child_allocation); } protected override void OnSetScrollAdjustments (Adjustment hadj, Adjustment vadj) { // This is to satisfy the gtk_widget_set_scroll_adjustments // inside of GtkScrolledWindow so it doesn't complain about // its child not being scrollable. } protected override bool OnExposeEvent (Gdk.EventExpose evnt) { if (!IsDrawable) { return false; } Cairo.Context cr = Gdk.CairoHelper.Create (evnt.Window); try { DrawFrame (cr, evnt.Area); if (child != null) { PropagateExpose (child, evnt); } return false; } finally { CairoExtensions.DisposeContext (cr); } } private void DrawFrame (Cairo.Context cr, Gdk.Rectangle clip) { int x = child_allocation.X - frame_width; int y = child_allocation.Y - frame_width; int width = child_allocation.Width + 2 * frame_width; int height = child_allocation.Height + 2 * frame_width; Gdk.Rectangle rect = new Gdk.Rectangle (x, y, width, height); theme.Context.ShowStroke = draw_border; if (fill_color_set) { theme.DrawFrameBackground (cr, rect, fill_color); } else if (fill_pattern != null) { theme.DrawFrameBackground (cr, rect, fill_pattern); } else { theme.DrawFrameBackground (cr, rect, true); theme.DrawFrameBorder (cr, rect); } } #endregion #region Gtk.Container Overrides protected override void OnAdded (Widget widget) { child = widget; base.OnAdded (widget); } protected override void OnRemoved (Widget widget) { if (child == widget) { child = null; } base.OnRemoved (widget); } #endregion } } |
From: Andrew C. <an...@op...> - 2010-10-15 00:07:06
|
On Fri, 2010-10-08 at 15:31 -0400, Andrew Cowie wrote: > A unit test would be good, too :) So, actually, I got curious, so went and added coverage for Context's inFill() and inStroke(). I did up some unit tests which seem to show this working, but since you had a real world application needing these methods, can you give them a try and let us know if they work the way you'd expect? Thanks, AfC Barcelona |
From: Andrew C. <an...@op...> - 2010-10-08 19:32:04
|
On Fri, 2010-10-01 at 23:45 +0200, Daniel Tschernatsch wrote: > Hello Java-Gnome developers, > > i'd like to use 2D graphics to interact with the user in my application. > Some pieces of my Cairo drawings (complex paths extracted from SVG) > should react when the mouse hovers over them or when they receive mouse > clicks. But I think there is one essential function missing from > Java-Gnome to accomplish this: cairo_in_fill: It... > > "Tests whether the given point is inside the area that would be affected > by a cairo_fill() operation given the current path and filling > parameters." > > Is it very hard to implement it in java-gnome? So, in general [when things are working :)], the answer is "no, it's not hard at all" The internal layers of java-gnome are generated; we start with ".defs data" (which are scheme-ish definitions of each type, enum, function, method, etc in the various GNOME libraries) [1] and generate various layers of code. The part we do NOT generate is the outside edge, the public API. That we leave to humans to decide what to expose, and how. Most of the time, though, exposing additional coverage is straight forward. For instance, the method you're looking for is cairo_in_fill() which really ought to be called cairo_context_in_fill() Assuming we had defs data for this method [2], our code generator would output a package visible method in org.freedesktop.cairo.CairoContext: static boolean inFill(Context self) { return cairo_in_fill(pointerOf(self)); } private native boolean cairo_in_fill(long self); and then there's a C part which implements that native declaration and calls the actual function. That's all already there. The part that a human has to do, if they so choose because they need it, like you do, is to expose the public API ("write the binding"). In this case, too easy: In [org.freedesktop.cairo] Context, public boolean inFill() { return CairoContext.inFill(this); } and that's it. You'll note that you get a REALLY BIG HINT as to what the public method should be called by what was generated, but that's where the humans come in - to decide what, in fact, the signature should be. Actually, it's not it - you need to write me some JavaDoc :) but you get the idea. And in an IDE like Eclipse, you'll have code completion and so can write this in seconds. A unit test would be good, too :) More info at http://java-gnome.sourceforge.net/4.0/doc/design/START.html especially http://java-gnome.sourceforge.net/4.0/doc/design/5a-Architecture.html If you want to try this yourself, let me know. I'd be happy to help get you started. AfC New York [1] Serkan is working on a parser for GIR .xml data, so soon we'll have up to date data for even more types! [2] Cairo is a bit more work, because we didn't have .defs information for its functions ahead of time. So someone has to write it, to then. But that's not too hard. [3] This sort of thing really belongs on the java-gnome-hackers mailing list, since we're [now] talking about engineering. Reply to there :) -- Andrew Frederick Cowie Operational Dynamics is an operations and engineering consultancy focusing on IT strategy, organizational architecture, systems review, and effective procedures for change management: enabling successful deployment of mission critical information technology in enterprises, worldwide. http://www.operationaldynamics.com/ Sydney New York Toronto London |
From: Andrew C. <an...@op...> - 2010-10-02 20:41:15
|
On Sat, 2010-10-02 at 13:12 +0200, Guillaume Mazoyer wrote: > (it seems that it's due to Metacity). Maybe try $ V=1 make doc AfC Kingston |
From: Guillaume M. <res...@gm...> - 2010-10-02 11:12:42
|
Hi, I just uploaded a new package to the java-gnome PPA. https://launchpad.net/~java-gnome/+archive/ppa It allows Maverick (Ubuntu 10.10) users to use java-gnome 4.0.16. You should know that the documentation package does not provide screenshots since it causes a FTBFS on Launchpad. I'll try to investigate this issue later (it seems that it's due to Metacity). By the way, a bug (with a patch) has been filled on Debian Bug tracker. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=588943 Regards, -- Guillaume Mazoyer - http://www.respawner.fr/ |
From: Daniel T. <dan...@gm...> - 2010-10-01 21:45:27
|
Hello Java-Gnome developers, i'd like to use 2D graphics to interact with the user in my application. Some pieces of my Cairo drawings (complex paths extracted from SVG) should react when the mouse hovers over them or when they receive mouse clicks. But I think there is one essential function missing from Java-Gnome to accomplish this: cairo_in_fill: It... "Tests whether the given point is inside the area that would be affected by a cairo_fill() operation given the current path and filling parameters." Is it very hard to implement it in java-gnome? The information that in_fill() should return is already present in fill(). So far I am very impressed how far java-gnome has come since 4.0. Best regards. Daniel Tschernatsch |
From: Max G. <max...@ep...> - 2010-09-11 03:01:02
|
Hi, I have already described my problem on your IRC, but nodody was able to solve it without concrete code. Since my program is somewhat big, I have written a small program that has the same problem; it is attached to this mail (don't worry, it's small). What I'm trying to do: I have an image viewing application like Eye of Gnome. Like in Eye of Gnome, MPlayer, VLC etc. a controller widget is being displayed while you move the mouse in fullscreen mode. If you haven't moved the mouse for a few seconds, the controller widget disappears and you see the image/movie only. While in fullscreen I need those MotionNotifyEvents. While not in fullscreen I have no use for them. Obviously my program works even when I receive tons of MotionNotifyEvents while I don't need them. So it's not a real priority. However it is bugging me since the documentation (http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gtk/Widget.MotionNotifyEvent.html) explicitly says that you ought disable this event once you don't need it anymore. This description, how to reproduce, the exact error message and my java-gnome version (the newest) can be found in the attachment. Thanks for your time and help, Max |
From: Andrew C. <an...@op...> - 2010-09-10 05:12:26
|
On Fri, 2010-09-10 at 02:08 +0400, Grigory Ptashko wrote: > I am a java developer and a linux user (currently it is ubuntu 10.04 > LTS). Nice. There's a PPA for people who want the latest released version of java-gnome, and there are lucid packages there. > awareness about whether the system is going to be shutdown or > hibernated or suspended etc Tricky. There doesn't seem to be a desktop wide means of providing such notifications, though some people talk to NetworkManager to find out. > > So my questions are: > 1. Can I at all write a gnome panel applet with java-gnome? Short answer: no. Medium answer: not yet. Long answer: more of an engineering discussion, but if you look at this message on java-gnome-hackers, you might get an idea of some of the considerations. http://article.gmane.org/gmane.comp.gnome.bindings.java.devel/1135 Since I wrote that, someone has contributed code to gnome-panel to make it no longer rely on Bonobo and use DBus instead, but my comment about IPC still being IPC whether it's over CORBA or DBus remains. And in any case, the fundamental machinery necessary to make an applet work remains convoluted and intricate, so it's a hard problem. That said, PanelApplet just descends from GtkContainer [ie org.gnome.panel.Applet would extend org.gnome.gtk.Container] so at a certain level all we need to do is that. It's more complicated because the thing to initialize an applet is a C MACRO, but we could do that in an Override. Once the next release of gnome-panel is out, then maybe we can look at this together... AfC Sydney -- Andrew Frederick Cowie Operational Dynamics is an operations and engineering consultancy focusing on IT strategy, organizational architecture, systems review, and effective procedures for change management: enabling successful deployment of mission critical information technology in enterprises, worldwide. http://www.operationaldynamics.com/ Sydney New York Toronto London |
From: Andrew C. <an...@op...> - 2010-09-10 05:12:18
|
On Wed, 2010-09-08 at 21:02 +0200, Guillaume Mazoyer wrote: > This error does not come from java-gnome. You should discuss that with > a Gnome Split developer (aka me) elsewhere :) Oh that's ok; I don't mind people chatting here or on IRC about how they're using the library in their projects... AfC Sydney |
From: Grigory P. <gpt...@cm...> - 2010-09-09 22:32:49
|
Hello. I am a java developer and a linux user (currently it is ubuntu 10.04 LTS). I feel that I am constantly missing some kind of panel applet in gnome so I've decided to develop it myself. The applet is going to be very simple. Only one interaction with outer world will be needed: the awareness about whether the system is going to be shutdown or hibernated or suspended etc. The panel applet will store some data through time and show some reports on a user's demand. So my questions are: 1. Can I at all write a gnome panel applet with java-gnome? 2. If yes then can I enable my applet to be aware of system shutdown etc? 3. Is there any preferred way to store data for panel applets? I am looking at SQLite. Thanks in advance. -- С уважением, Григорий Пташко +7 (916) 1489766 gpt...@cm... http://www.cmmt.ru |
From: Guillaume M. <res...@gm...> - 2010-09-08 19:03:10
|
Hi, This error does not come from java-gnome. You should discuss that with a Gnome Split developer (aka me) elsewhere :) Regards, Send from my HTC Hero Le 8 sept. 2010 06:12, "Adam Balan" <a-...@ho...> a écrit : First of all let me state I am sorry if this turns into a double post, I am posting this from Windows as Gnome mail client in Linux says it sent the message but it turns out the “outbox” states “unsent” So if it actually sent, I am deeply sorry for the double post. I recently Downloaded gnome-split 0.9 and placed the code into eclipse. It threw errors so I brought in (via reference library) dbus and gnome-java-4.0.16 which was compiled from source. This stopped all errors. I wanted to rebuild with modifications, the Dbusinhibitor in org.gnome.split.dbus package I believe it is and so in a new project I placed gnome-java-4.0.16 and dbus as refrenced libraries and began away. How ever I ran into an issue: Org.gnome.SessionManager does not exist. It actually doesn’t. What’s the issue? Gnome-split-0.9 DOES NOT throw any errors when compiled and that dbus file I mentioned earlier uses org.gnome.SessionManager; So why does Gnome-split not throw compiler issues? How can I use gnome’s session manager? This might be better suited at those familiar with gnome-split-0.9 source code. ------------------------------------------------------------------------------ This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd _______________________________________________ java-gnome-developer mailing list jav...@li... https://lists.sourceforge.net/lists/listinfo/java-gnome-developer |
From: Adam B. <a-...@ho...> - 2010-09-08 04:12:39
|
First of all let me state I am sorry if this turns into a double post, I am posting this from Windows as Gnome mail client in Linux says it sent the message but it turns out the "outbox" states "unsent" So if it actually sent, I am deeply sorry for the double post. I recently Downloaded gnome-split 0.9 and placed the code into eclipse. It threw errors so I brought in (via reference library) dbus and gnome-java-4.0.16 which was compiled from source. This stopped all errors. I wanted to rebuild with modifications, the Dbusinhibitor in org.gnome.split.dbus package I believe it is and so in a new project I placed gnome-java-4.0.16 and dbus as refrenced libraries and began away. How ever I ran into an issue: Org.gnome.SessionManager does not exist. It actually doesn't. What's the issue? Gnome-split-0.9 DOES NOT throw any errors when compiled and that dbus file I mentioned earlier uses org.gnome.SessionManager; So why does Gnome-split not throw compiler issues? How can I use gnome's session manager? This might be better suited at those familiar with gnome-split-0.9 source code. |
From: Andrew C. <an...@op...> - 2010-09-06 00:23:34
|
On Sun, 2010-09-05 at 10:00 -0600, Adam Balan wrote: > I am thinking of using another library with this one, That's fine. (in fact, that's the whole point; there are some rich libraries in Java land, and even more so, java-gnome has often been used to write rich front ends to [aspects of] enormous corporate enterprise application servers. If you can link the client library to communicate with it, then you can write a rich UI in java-gnome for it. This is actually one of java-gnome's PR problems; lots of people have used it, but for in-house work as opposed to full blown publishable packageable open source projects) > and I am wondering > for maximum optimization of a program dealing with threads which library > would be good to use? Well, {shrug} multi-threaded programming has its challenges, but java-gnome was written to be as thread safe as possible, given the constraints of the underlying libraries. Which is to say, you can have other Java threads running doing whatever, no problem. Only one thread at a time will be [able to] feed the GUI, but that's the same with any toolkit. > I was thinking of creating a instant messaging > service. Oh. So, why don' t you just use Pidgin or Empathy? Speaking of the latter, it's built on the telepathy framework, which adds presence to the GNOME desktop and the ability to talk to numerous different IM backends. We don't have coverage of telepathy as such, but it's something we could certainly think about doing. Other than that, whatever Java library you find you can use, no problem. I'm a little vague as to why you're trying to write an IRC client. There's not really a shortage, but if that's what turns your crank, you go right ahead. > I wanted to write the window and its features in Gnome-Java it's "java-gnome" > and create > the plug ins and what not using the same bindings. Sure > But I am not sure > what library would be good for dealing with threads and IRC chatting, as > it will be an instant messenger that deals with IRC. Well, there's always http://java-gnome.sourceforge.net/4.0/doc/examples/START.html#ExampleInstantMessenger :) Assuming you don't want to contribute to engineering a binding to telepathy any time soon, I can recommend instead: * the pircbot library. I've used it quite successfully over the years. It's really for writing bots but you can just as easily use it for full communication. http://www.jibble.org/pircbot.php * and, for Jabber, use Smack. It's lovely. http://www.igniterealtime.org/projects/smack/index.jsp * and, there aren't any other protocols that matter :) AfC Sydney |
From: Adam B. <a-...@ho...> - 2010-09-05 16:00:13
|
I am thinking of using another library with this one, and I am wondering for maximum optimization of a program dealing with threads which library would be good to use? I was thinking of creating a instant messaging service. I wanted to write the window and its features in Gnome-Java and create the plug ins and what not using the same bindings. But I am not sure what library would be good for dealing with threads and IRC chatting, as it will be an instant messenger that deals with IRC. If there are an example of IRC clients out there that deal with or use parts of Gnome-java I would be happy to take a look at them. |
From: Waldemar B. <wb...@gm...> - 2010-09-03 11:48:15
|
Am Freitag, den 03.09.2010, 12:46 +1000 schrieb Andrew Cowie: > On Thu, 2010-09-02 at 14:37 +0200, Waldemar Biller wrote: > > Anyway I'am asking myself, why this is not done automatically, when > > setting setActivable to true? > > That does sound pretty whacked out, but admittedly I've never used any > of the "live" features in a TreeView before; I always use them to > display data and get selections. > > I suppose the thing to do would be to build something similar with a > DataColumnString and a CellRendererText and see if you need to connect > to CellRendererText.Edited in order to update your TreeModel. As mentioned in the API this is mandatory. See here -> http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gtk/CellRendererText.html#connect(org.gnome.gtk.CellRendererText.Edited) > It could be that this is "just the way GTK is" but its always possible > we've missed something in our understanding... I just took a look at some GTK# examples and this seems to be the standard behaviour of the CellRenderer*. Changes to the data have to be done in an additional method. > AfC > Sydney > > ------------------------------------------------------------------------------ > This SF.net Dev2Dev email is sponsored by: > > Show off your parallel programming skills. > Enter the Intel(R) Threading Challenge 2010. > http://p.sf.net/sfu/intel-thread-sfd > _______________________________________________ java-gnome-developer mailing list jav...@li... https://lists.sourceforge.net/lists/listinfo/java-gnome-developer |
From: Andrew C. <an...@op...> - 2010-09-03 02:47:05
|
On Thu, 2010-09-02 at 14:37 +0200, Waldemar Biller wrote: > Anyway I'am asking myself, why this is not done automatically, when > setting setActivable to true? That does sound pretty whacked out, but admittedly I've never used any of the "live" features in a TreeView before; I always use them to display data and get selections. I suppose the thing to do would be to build something similar with a DataColumnString and a CellRendererText and see if you need to connect to CellRendererText.Edited in order to update your TreeModel. It could be that this is "just the way GTK is" but its always possible we've missed something in our understanding... AfC Sydney |
From: Miloud B. <go...@gm...> - 2010-09-02 18:58:18
|
Hi Adam, I was working on a poker game client that uses Java-gnome, it's not finished but there's a lot of Java-gnome code you could explore at http://bazaar.launchpad.net/~registry/aures/mainline/files <http://bazaar.launchpad.net/%7Eregistry/aures/mainline/files> Visit the client folder and if you have any question, just maillist it ;) Cheers, Miloud B. |
From: Guillaume M. <res...@gm...> - 2010-09-02 17:43:04
|
I don't have a real list but there are few projects like: Slashtime http://research.operationaldynamics.com/projects/slashtime/ GNOME Split https://launchpad.net/gnome-split Quill and Parchment http://research.operationaldynamics.com/projects/quill/ GMSO2 http://code.google.com/p/mso/ And probably other programs too. -- Guillaume Mazoyer - http://www.respawner.fr/ |
From: Adam B. <a-...@ho...> - 2010-09-02 17:29:10
|
I am wondering if any one knows of a list of projects/programs that currently use parts of or the entire gnome-java bindings project? I am new to the project and understand how it works on a fundamental level and would love to explore the source code of other projects either using bits of or the entire gnome-java 4.0.16 bindings project to further understand how it all works. Adam |
From: Waldemar B. <wb...@gm...> - 2010-09-02 12:37:20
|
Hmm... okay fixed this myself. The CellRenderToggle configuration should look like this. c = entriesTreeView.appendColumn(); c.setTitle("Download"); c.setClickable(true); CellRendererToggle r = new CellRendererToggle(c); r.setActivatable(true); r.setActive(ColumnName); r.connect(new CellRendererToggle.Toggled() { @Override public void onToggled(CellRendererToggle renderer, TreePath path) { TreeIter iter = store.getIter(path); store.setValue(iter, ColumnName, !renderer.getActive()); } }); Anyway I'am asking myself, why this is not done automatically, when setting setActivable to true? Am Donnerstag, den 02.09.2010, 14:23 +0200 schrieb Waldemar Biller: > Hey, > > I recently worked with the TreeView widget and came to this: > > I added a DataColumnBoolean with a CellRendererToggle. The Checkbox > shows up like expected, but I am not able to change the state of the > checkbox. > > Here's the source code. > > entriesTreeView = new TreeView(); > entriesTreeView.setModel(store); > entriesTreeView.setEnableSearch(true); > entriesTreeView.setHeadersClickable(true); > > TreeViewColumn c; > > c = entriesTreeView.appendColumn(); > c.setTitle("Download"); > c.setClickable(true); > CellRendererToggle r = new CellRendererToggle(c); > r.setActivatable(true); > > I also tried r.setActive(true) and r.setActive(ColumnName). Nothing > worked :( > The store is a object of the type ListStore. > > Hope someone can help me :) > |
From: Waldemar B. <wb...@gm...> - 2010-09-02 12:24:10
|
Hey, I recently worked with the TreeView widget and came to this: I added a DataColumnBoolean with a CellRendererToggle. The Checkbox shows up like expected, but I am not able to change the state of the checkbox. Here's the source code. entriesTreeView = new TreeView(); entriesTreeView.setModel(store); entriesTreeView.setEnableSearch(true); entriesTreeView.setHeadersClickable(true); TreeViewColumn c; c = entriesTreeView.appendColumn(); c.setTitle("Download"); c.setClickable(true); CellRendererToggle r = new CellRendererToggle(c); r.setActivatable(true); I also tried r.setActive(true) and r.setActive(ColumnName). Nothing worked :( The store is a object of the type ListStore. Hope someone can help me :) |
From: Serkan K. <se...@ge...> - 2010-08-31 06:02:10
|
Hey, It's great to see more users of this library. Quickly examining the code I see that you're mixing 2 toolkits (awt and gtk) which is bad. You can try using org.gnome.gtk.Clipboard(http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gtk/Clipboard.html) class for clipboard access. You'll probably wont need an extra thread using that as well (subscribing to OwnerChange sginal should work that out) Regards, Serkan |
From: Engin K. <eng...@gm...> - 2010-08-30 22:27:14
|
i made a click and run application it uses java-gnome if you want to visit : code.google.com/p/jcbr/ <http://code.google.com/p/jcbr/> I wish it can help to someone ,he wants to learn java-gnome |
From: Andrew C. <an...@op...> - 2010-08-29 03:00:23
|
On Fri, 2010-08-27 at 10:29 -0300, Douglaz wrote: > So what I did was change the sample code to use java-gnome only, > and I still can see the mem going up. Without having looked at your code to see if you're leaking anything, in general we do have a broader issue. I'm not especially concerned about it, but it's on the list of things to think about. Have a read of the thread starting at http://article.gmane.org/gmane.comp.gnome.bindings.java.devel/1432 It may be you're running afoul of that aspect of Java. AfC Sydney |
From: Douglaz <do...@gm...> - 2010-08-27 13:29:19
|
Hey AfC! Thanks for taking some time to check my code. You are right, the sample I attached was not properly written. But the application where I first noticed the issue uses java-gnome only. So what I did was change the sample code to use java-gnome only, and I still can see the mem going up. Any inputs would be very appreciated! Best regards, Douglas Sample code: import org.gnome.gdk.Event; import org.gnome.gdk.Pixbuf; import org.gnome.gtk.Gtk; import org.gnome.gtk.Widget; import org.gnome.gtk.Window; public class Main { public static void main(String[] arsg) { Gtk.init(new String[] {}); new Main(); } public Main() { super(); Window window = new Window(); window.connect(new Window.DeleteEvent() { public boolean onDeleteEvent(Widget widget, Event event) { Gtk.mainQuit(); System.exit(0); return false; } }); window.setTitle("Close to end"); window.show(); for (int i = 0; i < 10; i++) { new Loader().start(); } Gtk.main(); } protected class Loader extends Thread { @Override public void run() { while (true) { try { Pixbuf pixbuf = new Pixbuf("camera.jpg"); System.out.println(pixbuf); // Would set this Pixbuf in an Image to be shown on the screen; sleep(200); } catch (Exception e) { e.printStackTrace(); } } } } } 2010/8/27 Andrew Cowie <an...@op...> > On Thu, 2010-08-26 at 14:54 -0300, Douglaz wrote: > > import javax.swing.JOptionPane; > > import org.gnome.gdk.Pixbuf; > > You're trying to mix java-gnome and Swing. That's not going to work. > > [I could go on at great length about why mixing toolkits is a bad idea, > but what's relevant here, even if it is briefly "working" for you, is > that no one can help you diagnose things like memory problems when two > entirely different mechanisms for talking to the native graphics > libraries are at play]. > > AfC > Sydney > > > > ------------------------------------------------------------------------------ > Sell apps to millions through the Intel(R) Atom(Tm) Developer Program > Be part of this innovative community and reach millions of netbook users > worldwide. Take advantage of special opportunities to increase revenue and > speed time-to-market. Join now, and jumpstart your future. > http://p.sf.net/sfu/intel-atom-d2d > _______________________________________________ > java-gnome-developer mailing list > jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-gnome-developer > > |