|
Post by IsmAvatar on Feb 27, 2007 0:20:27 GMT -5
This topic is for discussion amongst the LGM teammates, as well as information regarding the Developer's Source Code, accessed via SVN. Language/IDELateralGM is developed in Java, in the Eclipse IDE, using Swing components. It is built largely from the ground up, to ensure maximal functionality for minimal filesize. FreeNot a penny has gone into the development of LateralGM. We do not take donations, because we have nothing to spend the money on, and would have no way of distributing the money amongst the developers. Thus, LGM is free of charge, free of restrictions, and free of Donate buttons. The TeamThe development team for LateralGM is small - about 3 or 4 people, and as a result, development isn't very fast. We encourage anyone with a knowledge of Java to help out to speed up the development process. PrerequisitesIf you wish to download the latest source code, or help us develop, you'll need some things. 1) Java 6 Development Kit ( download) 2) Eclipse Classic ( download) 3) Subclipse - Eclipse Subversion (SVN) ( instructions) 4) Eclipse Checkstyle ( website with instructions) 5) (developers only) An account in our openSVN repository. If you do not have an account, you will not be able to commit. In order to get an account, you will need to talk to me, and I will set one up for you. Alternatively, you could send your files to any of the developers, and we can commit for you. Formatting (every developer uses the same format, and here's how we enforce that) We're using a formatting for Eclipse called Girard, which should be included in the SVN Repository as of r192. We're using checkstyle for Eclipse with a style called LateralStyle, which should be included in the SVN Repository as of r73. Neither of these may be quite perfected, so if you have any corrections to make, feel free to submit them and I'll consider them for the official format (or simply commit your changes). Source Code and BugTrackerThe SVN Repository is located at opensvn.csie.org/LGM, choose the "LateralGM" folder, not the "LGM" folder (the "LGM" folder is outdated). OpenSVN hosts it, which offers Trac, which offers a Wiki, History (with differential highlighting), and Tickets (for requests, bugs, etc). The Trac can be found here: opensvn.csie.org/traccgi/LGM (thanks to Quadduc for realizing that it's there) If anybody can't connect to the SVN and wants the latest source, just say so and I'll upload a jar of it. Please realize that any jars uploaded here are UNSTABLE alpha and only for development purposes. If you are interested in trying out the stable release, please see the LGM Stable Releases topic. LicenseAs with the LGM stable releases, this is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This is the dev of the official version, meaning that if you make any changes, the rest of the dev team and/or ultimately myself (IsmAvatar) reserve the right to reject those changes and revert to a previous version. Therefor, I would encourage you to get a full understanding of the goal of this project before committing any changes here. Otherwise, you can take your changes elsewhere.
|
|
|
Post by Quadduc on Feb 27, 2007 11:54:52 GMT -5
JDK 6 installed (needed to do some JPackage stuff since I'm on Fedora). Successfully imported, compiled and run LGM 1.5 in Eclipse. Now I'm ready to try out SVN with Subclipse. Is that set up yet?
|
|
|
Post by IsmAvatar on Feb 27, 2007 19:45:48 GMT -5
Yes, it's been set up for some time. The entire version 1.5 was made with SVN, and TGMG and I exchanging commits. The SVN location is: opensvn.csie.org/LGM/LateralGMbut you'll need an account. I've set you up with one, and you should be receiving your username and password in the email address that you used to register for these forums.
|
|
|
Post by Quadduc on Feb 28, 2007 13:33:43 GMT -5
SVN checkout in Eclipse went smoothly, I haven't tried committing yet. Right now I'm playing around with LGM to see if there's something I feel like fixing/changing/implementing. The formatting of the LGM code is a bit unusual to me. It's not the built-in Eclipse style. I'm used to the default formatter (alternatively with braces on next line (except for arrays)). In any case, since it's a team project, I think it's best to store the formatter settings (org.eclipse.jdt.core.formatter.*) along with the project itself, if possible. If not, could you export your formatter settings and give me a copy? That way I could make use of the automatic formatter. clam: For the SVN/proxy problem, a Google search for subclipse proxy should give some results. From what I've read, you might have to edit the SVN configuration file or (in Windows) the registry. SVN configuration is documented at svnbook.red-bean.com/en/1.1/ch07.html#svn-ch-7-sect-1
|
|
clam
User
Even I don't know where my name came from!!
Posts: 30
|
Post by clam on Feb 28, 2007 18:55:41 GMT -5
Already tried the registry (unless I wrote to the wrong place). I came across something somewhere mentioning that some proxy servers may not support all the commands needed to use svn (at least not without specific server configuration).
Regarding Netbeans 6: GRRRRRRRRRRRR!!! I just changed to eclipse from netbeans, but I did like some of the things netbeans did, so I'll give it a go.
I can access the suppository through the web interface (without a password...) but it's tedious.
|
|
|
Post by IsmAvatar on Feb 28, 2007 19:43:19 GMT -5
Yes, since it is open source, we made it so that anyone can freely access the repository. I believe you have to be registered, however, to commit.
|
|
|
Post by Quadduc on Mar 2, 2007 2:36:19 GMT -5
If you can access the repository through https with a browser, then I'm quite sure Subversion should work with https too, because the proxy will just see an encrypted stream in both cases. Could it be that you're using the JavaSVN command-line client adapter? In that case maybe svnkit.com/kb/config-settings.html can help.
|
|
|
Post by Quadduc on Mar 3, 2007 17:23:11 GMT -5
I find the current SVN repository very slow, and Eclipse often times out when trying to do something like updating or getting diffs. It also seems that OpenSVN is hosted in China or thereabout and maintained only by a few people, which makes me feel that it is less stable than other SVN hosting alternatives. Because of this, I've done a quick search for other SVN hosting services and found some that might be worth a try: gna.org/ - Gna! provides SVN Repositories, Download Area, Web Pages, Mailing-Lists and Trackers (Bugs, Task, Support Requests, Patches) for projects under a GPL-compatible license. They have strict policies on what they host and support the GNU philosophy, see about.gna.org/. As a supporter of the GNU philosophy myself, I would certainly be happy to see LGM hosted here. Edit: As I said, they have very strict policies. One of the requirements is that the project must not depend on proprietary software - LGM does that with Java 6. However, Sun Java is in the process of being licensed under the GPL, so this problem is disappearing... code.google.com/hosting/ - "Our new hosting service offers a collaborative development environment that includes: project workspaces with simple membership controls; version control via Subversion; issue tracking; mailing lists at groups.google.com." Google Code project hosting requires that one of a certain set of licenses is used, and I think gna.org does that too. So if we're going to get hosting with one of them, we might need to change the current license. The MIT License ( en.wikipedia.org/wiki/MIT_License) is very similar to the current one (which is basically free-for-all). However, the GNU GPL ( www.gnu.org/licenses/gpl.html) is my personal favorite as it ensures that the program remains free software, but it is a more advanced license. I'm for a change to either of those, because they are well known and listed as free licenses by the FSF. Besides, all big/successful free software projects that I know of are under a standard license like the GPL or the MIT License. So, what are your thoughts on changing the license and hosting of LGM?
|
|
|
Post by IsmAvatar on Mar 4, 2007 1:53:39 GMT -5
Thank you very much, Quadduc, you're already proving to be an invaluable asset to the team. I'm all in favour of moving to a better SVN server. In fact, I wouldn't mind a general alternative to SVN, but seeing as it's free and better than nothing, it's what I went with with the council of TGMG.
I've been considering setting up a license for most of my projects including LGM, but haven't really gotten around to it (it takes a lot to weed through the legal jargon). I started reading the GNU GPL and liked it, but didn't fully understand it so I wasn't certain if it best reflected my interests. The best I could do to express my interest was to call it "Open Source" I will continue to research these licenses and try to get a definitive answer soon.
|
|
clam
User
Even I don't know where my name came from!!
Posts: 30
|
Post by clam on Mar 6, 2007 23:41:07 GMT -5
If you're after a free alternative to SVN, there's always CVS, which a lot of linux and GNU projects use. Of course, I think the idea of SVN is to add extra functionality to CVS, so there may not be much point, but there's probably more free CVS hosts.
edit: Finally managed to checkout using the command-line client!
|
|
|
Post by Quadduc on Mar 7, 2007 12:14:04 GMT -5
CVS has some problems that SVN was made to solve. The first time I tried to set up CVS was also my last one. The problems I had with CVS drove me mad.
I've noticed that there are some inconsistencies in the current formatting of the LGM code. It would be great if we could standardize on a common formatting. That way, correct formatting would be as simple as Ctrl+Shift+F before every commit. For this to work, we all need the same formatter settings. The simplest way to do this would be to use the default formatter called "Eclipse [built-in]" (is everyone using Eclipse?). Another soulution is to have one team member export their formatter settings for the other members to import. The reformatting of the project would best be done in a single commit, with no other changes in that same commit. Any thoughts?
|
|
clam
User
Even I don't know where my name came from!!
Posts: 30
|
Post by clam on Mar 8, 2007 18:52:26 GMT -5
The inconsistent formatting is because some of the code that I originally sent to IsmAvatar has not been touched since, and I wrote it in NetBeans 5, which has a very limited set of options for code formatting, as opposed to almost too many options in Eclipse! I think a standard set of format options would be excellent, and I certainly don't have a problem with the Eclipse default format.
@ismavatar I've noticed that the structure changes that have been made to Gm6File have made the "Resource container" a static member, which means there can only be one effective instance of Gm6File at a time - what happens if you want to load two files and merge them?
Also, I think the solution to the excessive resource handling functions I devised would probably work better than the new system. It uses generics, so it removes the need for explicit casts, and a general get-by-type-and-id could be added easily.
I've looked up how the clone() method works, and it does do a bitwise copy for you (if you call super() ), but you still need to duplicate everything referenced by it, so basically it would just let you add extra primitive members without needing to update the copy code.
edit: (there's always something I forget to say) The "servers" config file I used with the svn command line client also works with subclipse, except I had to provide the password as a command line parameter in order to checkout, and Eclipse just fails rather than prompting for a password...
|
|
|
Post by Quadduc on Mar 9, 2007 18:57:48 GMT -5
I've just finished externalizing a lot of UI strings in LGM. This makes translating or correcting a typo a lot easier, as the strings are moved to their own files, separating code and UI text.
However, it was a bit more work than I had expected, because things like the ActionEvent stuff and the icon code identified the buttons and menu items by their English strings. I have changed this so they now use the string keys (strings used to identify the newly externalized strings, don't know if they have any official name). But this means that some coding needs to be done differently.
For example, if you want to create a new menu item in GmMenuBar, you first need to make a new key (a string like e.g. "GmMenuBar.FOOBAR") for this item, then add this key with its corresponding text to the file componentRes/messages.properties (e.g. 'GmMenuBar.FOOBAR=Foo Bar'), and then add the right menu.addItem call, with the key as first argument. The item will then have the text you entered in messages.properties.
If you want an icon with that, just add a line in mainRes/icons.properties, e.g. 'GmMenuBar.FOOBAR=foobar.png', and it will use icons/foobar.png.
The menu item will also pass its key to the Listener class, instead of the UI string like it did before.
All this may seem complicated, and it's a bold change, but I think it's worth it, as it allows changing strings without any danger of breaking a function.
|
|
|
Post by IsmAvatar on Mar 10, 2007 1:23:35 GMT -5
clam (cvs/svn) TGMG and I had already looked into this. I was originally only aware of the existance of CVS, but we weren't able to get it to work (can't remember the details - I think there might have been a cost involved?) Quadduc (formatting) A single format exists that I have uploaded that I've been trying to encourage the use of: users.nni.com/cmagicj/girard.zipRealise it is not quite perfected - in particular, variable declarations as appear outside of methods will have spaces between each and every one of them, so you have to go back and delete all those spaces, which is really annoying, and if anyone can solve this, please upload a corrected format. However, as clam stated, some code is in there that I have not touched since clam first coded it in a different format, simply because it takes a little time to go through and correct any formatting problems that arise each time I use ctrl+shift+f. Again, I encourage you to download this format and make any possible corrections to it you want for problems that arise with it (especially the one I noted above). I will link this in the first post. clam (static gm6file) This change was made for easier access from other classes. As always, if you have a better idea, feel free to go in and change it. (generics) I believe this is the system I now use. I don't recall if this is in the latest stable release, but it is definately in the latest commit. (clone) So we could just call the clone method without overwriting it, and then just modify the pieces that we don't want cloned? Like I said, feel free to do whatever modifications you want. I understand that you don't really have the perfect system to work with here, but I am without any access to JDK for the next week or so, so I think you're better off than me >.< (subclipse) Not quite sure what you just said, but it sounds like "it didn't work", so I guess I'll just say good luck with it and maybe something else will work or someone else will be able to help you more. Quadduc (externalized strings) Hmm, never considered that. I can't really imagine that typos would be that hard to find that we have to externalize the strings, but hey, if you say so. Yes, I do identify events by strings, since I don't know of much of a better way that doesn't require twice as much coding, but I guess what you're doing will work. In this particular matter I had efficiency and coding ease over future corrections, but I suppose this is a small sacrifice that I don't see any harm in, and will probably be worth it in the long run. I'll have to see how much the code has changed when I come back to it in a week or so, sounds like it might take a brief moment to get a hang of the new system. Self Update - I'm actually on "vacation" now for the next week or so in that I no longer have access to my own computer with JDK and eclipse on it. I have installed these on another computer, but don't really expect to be doing much LGM work on it right away. My government job that I had about the same time as LGM that put it on hold for a little has summoned me again, hense the "vacation". Not to worry, this should not be an indefinate postponement, we have a deadline this time and it is very soon, and also you guys are obviously working on the code now so I know the project keeps moving forward even when I am not active. Sorry to suddenly dump this on you, but it was kind of a surprise to me as well. I still have internet access throughout the week, although somewhat restricted since it is someone elses computer, but I still will frequent these forums and be more than happy to talk with you guys. You will not be able to find me on IM (all my buddies are going to think I'm dead!). Sounds like everything's getting going pretty well. As always, if you need me, drop me a message or post here (not that you haven't been utilizing this already) and I'll get back to you as soon as possible. I'm still looking into the license stuff.
|
|
|
Post by Quadduc on Mar 10, 2007 16:43:07 GMT -5
I've done some changes to the format, it's available at quadduc.ath.cx/~stian/formatter.xml (right click and save link). It should eliminate blank lines between "field declarations". I also changed it so it puts spaces after commas in some places where I think this improves readability - e.g. void bar(int foo, fooClass y) instead of void bar(int foo,fooClass y) The latter one doesn't separate foo,fooClass clearly enough, at least with my font/screen/eyes combination. About the string externalization, the main reason was that I wanted to allow for translation of LGM. I've actually made a fairly (for now) complete translation into Norwegian Bokmål, and it works too. I've found only one problem, which is the names of the primary groups, the game info resource and the game settings resource in the resource tree. These names are saved with the gm6 files, and AFAIK, they cannot be changed in GM6. So I'm wondering how LGM should deal with this. Some options: - LGM always uses its own language-specific names in the GUI, but uses the "official" names (or what was already stored in the file) when saving.
- LGM always uses the "official" English names both when saving and loading and doesn't allow the user to change these names.
- LGM loads and uses the names in gm6 files it loads and uses its own language-specific names when creating new ones. The user can change the names.
For normal use, I think the first one (basically ignoring what names are stored in the file) is best. What do you think?
|
|