java-gnome-developer Mailing List for The java-gnome language bindings project (Page 15)
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: Adam A. <eid...@gm...> - 2009-01-23 10:58:05
|
Andrew Cowie wrote: > On Mon, 2009-01-19 at 16:37 +0100, Adam Ambrus wrote: >> in this case, File->Quit hangs the application. > > Works for me. > hm... then it must be a problem on my side... i do not know whether i want to debug it :D > >> also, there is a problem with the initialization process - i have to >> restart the jvm everytime > > Um, I'm not really sure what you're doing, but whatever it is you must > only be calling Gtk.init() once per process. > i run the main class from BlueJ (which we use in school...). this case is replicable on multiple computers. > >> in real life >> there should be a standalone process for each application, right? > > Yes. Desktop apps are one process per application. > great, so i won't have to bother with this :) thanks. -AA |
From: Andrew C. <an...@op...> - 2009-01-23 08:54:04
|
On Mon, 2009-01-19 at 16:37 +0100, Adam Ambrus wrote: > in this case, File->Quit hangs the application. Works for me. > also, there is a problem with the initialization process - i have to > restart the jvm everytime Um, I'm not really sure what you're doing, but whatever it is you must only be calling Gtk.init() once per process. [Running a program always involves running a new VM. The only context you don't do that in with monster J2EE application servers which are intended (only) to run code designed to a specific life cycle API and have specific deployment hooks for that purpose] > in real life > there should be a standalone process for each application, right? Yes. Desktop apps are one process per application. AfC Hobart |
From: Adam A. <eid...@gm...> - 2009-01-19 15:38:07
|
hello, after my successful launching of java-gnome-4.0.9, i was playing around with the examples. i use bluej for development of applications, which successfully imports all of the examples. however, in ExampleSimpleMenu, there is a problem with quitting. in this case, File->Quit hangs the application. also, there is a problem with the initialization process - i have to restart the jvm everytime i want to start a new instance of an example. it gives an error about a library already loaded into memory. i can give more information if needed. otherwise, does anyone have an idea what could be done with this? i suppose that the jvm restart is only a bothering fact; in real life there should be a standalone process for each application, right? but i am worried about the File->Quit. thank you for answers -AA |
From: Andrew C. <an...@op...> - 2009-01-18 01:07:59
|
On Sat, 2009-01-17 at 16:18 +0100, Goundy wrote: > Well I'm requesting some advices about implementing multi lingual > application Our i18n support is in the Internationalization class: http://java-gnome.sourceforge.net/4.0/doc/api/org/freedesktop/bindings/Internationalization.html but see also: http://bugzilla.gnome.org/show_bug.cgi?id=531601 ++ Look at Slashtime for a real-world working implementation of this in a java-gnome based application. Translations exist for fr_CA and tr_TR. The hard part is the build infrastructure to support building the intermediate and message files. But you can manage that any way you please. The real point is to create the .po files from which your build can create the .mo files. Don't commit the .pot file to your version control system. ++ > I use libglade for my GUI, and I told myself let's create different glade > XML files for each language I don't use Glade for UIs anymore, but I can tell you 100% that this would be incorrect. Glade .xml files can be have their strings marked for translation and then those strings extracted like any other internationalized artifact. 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: Goundy <go...@gm...> - 2009-01-17 15:20:24
|
Hi guys. Well I'm requesting some advices about implementing multi lingual application when using java-gnome. I use libglade for my GUI, and I told myself let's create different glad XML files for each language I want to use, and then store other informations like error messages, warnings, informations... in seperated text files (for each language). But I'm not sure I'm using the nicest idea, do you have some better ideas in mind ? Thanks in advance |
From: Jacek <ja...@gm...> - 2009-01-15 15:18:28
|
* bump * Sorry for the bump, but I would really like to have a shot at this (i.e. implementing my own custom layout manager), but so far I don't have an idea as to how to intercept the GTK+ layout management logic and override it with my own.... Thanks in advance... Jacek wrote: > > Could someone point me to some code samples of custom layout management > (i.e. overriding the base behavior of let's say VBox to do your own > layout)? I presume it can be done, but I'm not sure how to go about it. > > Thanks in advance.... > -- View this message in context: http://www.nabble.com/Custom-layout-management--tp21090358p21479728.html Sent from the Gnome - Java Binding - General mailing list archive at Nabble.com. |
From: Adam A. <eid...@gm...> - 2009-01-10 21:14:11
|
well, assuming the package messing (previous email) solved the problem, i guess i just removed the whole directory just to be sure that it is going to be a clean compilation. it was because after number of recompilations and reconfigurations, i got first the error with somedir/somefilename_GtkAboutDialog.h (java exception was thrown), and then some Plumbing.c compilation error. that were the reasons forcing me to have a rather clean stuff to mess with - luckily java-gnome is not a mammoth in occupied space ;) Andrew Cowie wrote: > On Sat, 2009-01-10 at 12:10 +0100, Adam Ambrus wrote: >> so i managed to get it working :) only thing needed to be done was to >> remove the dir, untar again and ./configure && make :) > > Ok, that's weird. > > In an ideal world full of sunshine, roses, and butterflies, I'd like to > hope that that wouldn't be necessary. The state is held in .config, so > successfully completing ./configure should have cleared your problem. > > {shrug} > > AfC > Sydney > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Check out the new SourceForge.net Marketplace. > It is the best place to buy or sell services for > just about anything Open Source. > http://p.sf.net/sfu/Xq1LFB > > > ------------------------------------------------------------------------ > > _______________________________________________ > java-gnome-developer mailing list > jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-gnome-developer |
From: Andrew C. <an...@op...> - 2009-01-10 20:31:27
|
On Sat, 2009-01-10 at 12:10 +0100, Adam Ambrus wrote: > so i managed to get it working :) only thing needed to be done was to > remove the dir, untar again and ./configure && make :) Ok, that's weird. In an ideal world full of sunshine, roses, and butterflies, I'd like to hope that that wouldn't be necessary. The state is held in .config, so successfully completing ./configure should have cleared your problem. {shrug} AfC Sydney |
From: Adam A. <eid...@gm...> - 2009-01-10 11:10:23
|
hi, so i managed to get it working :) only thing needed to eb done was to remove the dir, untar again and ./configure && make :) now my only problem is finding the media framework. if you could help me with this, i would very appreciate it. thanks for support. -AA |
From: Adam A. <eid...@gm...> - 2009-01-10 10:38:31
|
hello again, so i finally removed the 'gcj' package as suggested, and installed openjdk-6-jdk (with dependencies) and purged all sun-java-6 packages. but now i get a different error; here is the output of "./configure && make": ---- equivalence, v0.2 ...configuring Java projects to build and run on Linux & Unix Identify operating system: Debian Check for required jar files: - JUnit test framework found Check for required system libraries: - GTK+ found - Pango found - ATK found - GDK found - LibGlade found - GNOME printing (Unix backend) found Check Java compilers: - System javac works - System javah found #here is reflected the gcj removal - GNU fastjar works - System javadoc found Check Java virtual machines: - System java VM works - GNU gij works Check native compiler: - GNU gcc works Select compiler: javac Select runtime: java Output: - configuration data ok - native library location ok GCC src/bindings/org/freedesktop/bindings/Plumbing.c In file included from src/bindings/org/freedesktop/bindings/Plumbing.c:15: tmp/include/org_freedesktop_bindings_Plumbing.h:5:1: error: unterminated #ifndef make: *** [build-java] Error 1 ---- any more ideas? thank you so far for support. -AA PS: getting back to my original project, can you suggest a media framework for Java to play audio/mp3 files? so far i've found JMF, but i have trouble making it work as well ^^ |
From: Andrew C. <an...@op...> - 2009-01-10 02:45:46
|
On Sat, 2009-01-10 at 00:45 +0100, Goundy wrote: > requires refreshing the game area each time a [something > happens] ...I do drawing in the ExposeEvent of an Image > just like the example So those would probably have better been DrawingArea instead of Image; I've recently been doing some work with Poppler and did up the basics of DrawingArea while I was at it (it was pretty preliminary). Ping me next time we're online together I can tell you how to cherry pick it from the branch it's on. [it's revno 594 on my 'poppler' branch] http://research.operationaldynamics.com/bzr/java-gnome/hackers/andrew/poppler/ > but I really don't see how should > I do to be able to draw at a given moment ! I think what you want is Widget's getWindow() http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gtk/Widget.html#getWindow() then Window's invalidate() http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gdk/Window.html#invalidate(org.gnome.gdk.Rectangle,%20boolean) Let us know if it works! ++ As for your other problem, you'll only get Button.Clicked if the thing you are drawing on (over) is a Button. You may want Widget.ButtonPressEvent http://java-gnome.sourceforge.net/4.0/doc/api/org/gnome/gtk/Widget.ButtonPressEvent.html 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...> - 2009-01-10 02:42:42
|
On Thu, 2009-01-08 at 20:18 +0100, Adam Ambrus wrote: > so you suggest a complete move to openjdk? If you have access to it, and no policy reasons not to use it, then definitely. And in so far as Sun's Java has usually been backwards compatible, there's little reason not to. icedtea 1.6, 1.7 or openjdk 1.7 ; doesn't matter. Regardless, java-gnome doesn't use *anything* in areas of Sun's standard library that are proprietary and patent encumbered (which makes sense; the stuff in the binary plugs was mostly the graphics stuff from Kodak, and we sorta use someone else's widget toolkit :)) So you can just worry about finding a VM that works period and you'll be set. As for "which is better", that will of course entirely depend on what your application is doing and how you tune it, but I don't think you'll find java-gnome the bottleneck. [we have areas we're working to improve, naturally, but nothing urgent at this point - indeed, every risk of premature optimization. The initial design decisions and architecture are holding up very well] 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...> - 2009-01-10 02:28:51
|
On Thu, 2009-01-08 at 16:32 +0100, Peter Mosseveld wrote: > It is a really a great tool kit! I'm sure everyone who has contributed to the library appreciates you saying so. > ProgressBar & ProgressBarOrientation ... > I would expect to be able to > setOrientation(ProgressBarOrientation.BOTTOM_TO_TOP). Yes, that sounds reasonable. > Are there plans to extend the > functionality of the ProgressBar in the current release? anyone wearing their "hacker" hat would say: ------------------------------------------- The answer for that is the same for anything; if someone needs a particular thing then they are welcome to contribute it. Speaking personally, I *myself* haven't *yet* need such thing [yet], so I *personally* haven't added coverage for it. returning to my "developer" hat: ------------------------------- I am quite curious to know what you'd need a vertical ProgressBar for. Can't say that I can think of any apps I have that use such a thing. What are you planning to do with it? Whatever it is, I imagine it'll be pretty cool. I am always interested to hear what people are working on and how they're intending to go about achieving it. putting my "hacker" hat back on, -------------------------------- The answer to the last question probably turns out to be just the thing to have in the API documentation describing setOrientation() - what it's for, and under what situations you might want to use it. and lastly, with the project "maintainer" hat on: ------------------------------------------------ by design, java-gnome is particularly easy to work on; exposing the functionality you are talking about it will be as simple as adding a one line method and doing up a couple Constants. Too easy. I invite you to consider doing so yourself. If you do, I hope you will contribute that work to the project and thence to others. Do drop by #java-gnome. I'm sure you'll find people willing to help you get bootstrapped. Like any vibrant project, lots of people in different timezones and with varied work schedules, so perhaps be patient if you do. AfC Sydney |
From: Goundy <go...@gm...> - 2009-01-09 23:47:14
|
Hi everyone, I just tried to draw some images using Cairo well it actually works ! But I've some conception problems. I'm developing a game that requires refreshing the game area each time a command is received over network (Poker game). At this moment, I do image printing in the ExposeEvent of a Image (GtkImage) just like the Afc example, but I really don't see how should I do to be able to draw at a given moment ! Any ideas about this ? Second question (might be silly) but I really have no idea about it: Say: Button btn = new Button("Do Something"); btn.connect(new Button.Clicked(){ @Override public void onClicked(Button arg0) { // Here I want to access some classes instances instantiated somewhere } }); What I want to do are things like: - When a button A is clicked: Send some data over some Socket descriptor - When a button B is clicked: Change some part of the GUI (redrawing,... etc) But I've no idea on how to pass arguments to these events... any help? Thank you. Miloud Bel. |
From: Jacek <ja...@gm...> - 2009-01-09 00:04:04
|
Well, that's what I am using and I managed to compile it without any major issues... -- View this message in context: http://www.nabble.com/compiling-java-gnome-4.0.9-stable-tp21353956p21363797.html Sent from the Gnome - Java Binding - General mailing list archive at Nabble.com. |
From: Adam A. <eid...@gm...> - 2009-01-08 19:18:42
|
ah. so you suggest a complete move to openjdk? Jacek wrote: > It looks like you have the old gcj java runtime, which OpenJDK made pretty > much obsolete...I am guessing if you remove it via Synaptic, it should > properly use OpenJDK? > > I don't think there is much of a difference between OpenJDK vs SUn Java in > terms of performance, with the exception of applets (the new 6u10 changes > are not rolled into the OpenJDK yet). For Java 7, the plan is that the two > will be identical. |
From: Jacek <ja...@gm...> - 2009-01-08 18:59:22
|
It looks like you have the old gcj java runtime, which OpenJDK made pretty much obsolete...I am guessing if you remove it via Synaptic, it should properly use OpenJDK? I don't think there is much of a difference between OpenJDK vs SUn Java in terms of performance, with the exception of applets (the new 6u10 changes are not rolled into the OpenJDK yet). For Java 7, the plan is that the two will be identical. -- View this message in context: http://www.nabble.com/compiling-java-gnome-4.0.9-stable-tp21353956p21358542.html Sent from the Gnome - Java Binding - General mailing list archive at Nabble.com. |
From: Adam A. <eid...@gm...> - 2009-01-08 18:21:22
|
hi, i am also using Ubuntu 8.10, but I use Sun Java. and btw, which Java implementation offers better performance? OpenJDK or the Sun Java? i heard that so far the Sun Java is the fastest, that's why i use it. -AA Jacek wrote: > What distro are you on? > > I was able to compile it on Ubuntu 8.10 without any issues (outside of some > missing dependencies reported during the configure, which I had to add from > the repos), with OpenJDK installed from the regular repositories. > |
From: Jacek <ja...@gm...> - 2009-01-08 15:35:49
|
What distro are you on? I was able to compile it on Ubuntu 8.10 without any issues (outside of some missing dependencies reported during the configure, which I had to add from the repos), with OpenJDK installed from the regular repositories. -- View this message in context: http://www.nabble.com/compiling-java-gnome-4.0.9-stable-tp21353956p21354177.html Sent from the Gnome - Java Binding - General mailing list archive at Nabble.com. |
From: Peter M. <pm...@xs...> - 2009-01-08 15:32:15
|
Hi, I am using java-gnome 4.0.6. It is a really a great tool kit! it brings the power of java to gnome. I have a question about the ProgressBar & ProgressBarOrientation implementation. Although there is a class ProgressBarOrientation, it seems to be empty. Also there is no method in ProgressBar to set the orientation. I would expect to be able to set the orientation using a method like (equivalent to what you have in gtkmm): setOrientation(ProgressBarOrientation.BOTTOM_TO_TOP). Can I set this property in another way? Are there plans to extend the functionality of the ProgressBar in the current release? Thanks Peter. |
From: Adam A. <eid...@gm...> - 2009-01-08 15:24:35
|
hello, i am about to do work for the school, which involves creating a Java program (surprisingly) on any topic. i have chosen to do a media player, or more precisely music player. the aim is to write a lightweight, powerful player for the GTK/Gnome environment (as i plan to use it on my machine afterwards :)) now, the problem. the issue occurs at the 'make' step of the building process. i always end up with a message similar to: " Exception in thread "main" java.io.IOException: can't find class file java/lang/Object.class in java.net.URLClassLoader{urls=[file:/home/eidam/Software/Dossier/java-gnome/java-gnome-4.0.9/tmp/bindings/,file:/usr/lib/jvm/java-1.5.0-gcj-4.3-1.5.0.0/jre/lib/rt.jar], parent=gnu.gcj.runtime.SystemClassLoader{urls=[file:/home/eidam/Software/Dossier/JMF-2.1.1e/lib/jmf.jar,file:./,file:./], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}} " i see that it searches in some weird directories, i am especially worried about the "/usr/lib/jvm/java-1.5.0-gcj-4.3-1.5.0.0/jre/lib/rt.jar" thing, as i have java sdk 1.6 up and running. i would appreciate any help in getting rid of this problem. -AA |
From: Ben B. <lin...@bu...> - 2009-01-03 04:06:24
|
Hey, this seems to be a hot and very emotional topic. But I am currently writing an app that was intended not only for me, but for a specific user group which happens to run Windows. I can't help it, although you can be sure I share your opinion about this Redmondish OS. So, I face the two options: Make java-gnome run on Windows, or dump my app and rewrite it from scratch. It's still fairly early in the dev cycle, so it's an option. But I like java-gnome. And I think running only on one OS will be a deterrent for java-gnome, so I think the project will profit from being able to run on Windows, even if some project members couldn't care less *cough*. So, I was asking for the actual problem Andrew Cowie, was rather mystical "It's something deep", but said it's about thread-safety and the fact that GDK-Win32 simply doesn't implement the thread-safety mechanism used by java-gnome. Or something like that - I couldn't get much more facts out of him. He did point me to the same documents about thread-safety that he posted today in the other thread. I read them, and actually understood most of them, but I still don't see how that's a blocker for java-gnome on Windows: If the app is single-threaded (which the majority of GUI apps are, and mine is) (or java-gnome calls are only made from one thread, which should amount to the same thing), then the whole thread-safety issue is simply irrelevant, no? The only problem I could imagine is that java-gnome uses GDK APIs which are simple not implemented for GDK-Win32 at all, and that simply breaks stuff so nothing works. But, if we accept the restriction on single-threaded for now, these APIs are implemented as skeletons, with no implementation: keeping the app going, just without making the assurances about threads that they promise. Then single-threaded apps should work, no? Andrew said this would be 70% of the way. The other question is: What's the other 30%? Greetings. Respectfully, Ben |
From: Goundy <go...@gm...> - 2009-01-02 18:40:01
|
Hi everyone. Well, Afc here's the patch I did. I hope I didn't screw up anything :P And if it's okay, just tell me what you want me to work on next. Cheers Miloud Bel. aka Goundy |
From: Jacek <ja...@gm...> - 2009-01-02 16:29:05
|
Impressive...so I could basically update the state of a UI component (e.g. a progress bar) from a worker thread without any concerns. Very cool. For the website, I think it would be very useful to add a Wiki engine to entice newbies such as me to post answers to the most common issues. Best regards, Jacek -- View this message in context: http://www.nabble.com/How-do-you-fire-an-event-on-the-main-Gtk-thread--tp21128584p21253522.html Sent from the Gnome - Java Binding - General mailing list archive at Nabble.com. |
From: Andrew C. <an...@op...> - 2009-01-02 07:32:53
|
On Mon, 2008-12-22 at 06:18 -0800, Jacek wrote: > In Swing, you use SwingUtilitilies.invokeLater(Runnable) for this. > In SWT, it's Display.asyncExec(Runnable). > > What is the equivalent API for Java-Gnome? There isn't one. java-gnome is thread safe. Hooray, thank god, happy new year, etc. ++ I wrote about this a long time ago; sorta surprised you missed it seeing as how it's the first hit for "java-gnome thread": http://research.operationaldynamics.com/blogs/andrew/software/java-gnome/thread-safety-for-java.html but our wonderful thread safety *is* mentioned in the public API documentation here: http://java-gnome.laptop/4.0/doc/api/org/gnome/gdk/Gdk.html and was written about in the release notes a number of times, as far back as 4.0.3 when it was introduced: http://java-gnome.sourceforge.net/4.0/NEWS.html#4.0.3 . Anyone in our IRC channel could have told you about it, I'm sure. Anyway, no messing around with idle callbacks or any other such nonsense. Just use a worker thread, but be aware that a) signal handlers run in the main thread (and are already within the GDK lock throughout), and b) holding the main lock and blocking the main loop are synonymous, so the injunction to get on with things that applies to signal handlers really applies globally. ++ Perhaps this needs to be noted a bit more prominently. We haven't worked on the website for a while, so perhaps it's time for some changes. Discussion of how best to do so to java-gnome-hackers; suggestions [in patch form] for the site always welcome. The current site is based on the 'website' branch from the usual place (although the website code is in *every* branch of java-gnome, in web/public/). 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 |