I would like to have the option to have to have different maps tabbed and integrated as the mainmap. To get rid of lots of additional windows needed to play the module. This will add to a more polished look&feel.
Currently this leads to a flood of Exceptions. Seemingly the Tabbed pane get set up wrong to qualify further as a proper handle for drawing funtionality. Also i see the namespace and thus classname differences.
Tabbed components is something we intend to support in either 3.2 or 3.3
(this depends on how quickly we can dispose of the other items on our
list for 3.2). Right now, we’re thinking June for 3.2.
That’s why it doesn’t work. If you can’t make one element a child of another
via the Editor, then it’s very probable that doing so by hand will cause
your module to fail catastrophically.
We’d be happy to have you. There are lots of small jobs which we could
use help on, as well, as you get up to speed. Don’t hesitate to ask for
advice w/r/t the code—there’s a lot of it (120k lines) and there is
no one person who has it all in his head anymore, but someone among the
three old-timers (Rodney, Brent, and myself) will know why things are
the way they are.
Well i did not just edit the buildfile at will. I created all the controls (Tabed pan, etc etc) to have a mesh where i pasted the MapWindow code i already had at the spot there control reach the “old” namespaces. This is st VASSAL.[…].BoardPicker iirc. This is “not ok” but saves lot of work if you redesign a module during creation at a point where you have lots of work already done (Like when i relized i cannot c&p maps into tabbed panes via the Editor - I know now that can just exchange the Boards and MapTraits as they share the same set of classes, this works in the editor as well concludingly, but it took me the detour via the manual editing to get behind that ) To the manual editing is not the reason here.
I have to find a way for developing java i am comfortable with first… then i will get into the code and eventially come to the point where i can contribute. Hopefully!
For now just explain what the makefiles form your branch do around in the trunk just kidding…
No, I’m not saying it’s because of the hand-editing—I do hand-editing
myself fairly often. It’s because the WidgetMap isn’t designed to to
be used that way. All I was saying is that it possible to create something
which is syntactically correct XML but will throw exceptions when you
run it if you’re hand-editing.
Brent and Rodney use Eclipse for development. I work in Vim and build
with a Makefile. I’m not sure what Michael is using.
There’s a lot of shell scripting going on in my Makefile; most of the
targets have to do with building releases, not with building the
Java classes. If you do a ‘make all’, it’s just this part which runs:
i18n: $(CLASSDIR)
for i in cd $(SRCDIR) && find VASSAL -name '*.properties'; do cp $(SRCDIR)/$$i $(CLASSDIR)/$$i; done
The $(CLASSDIR) target makes the directory where the compiled classes
will go. The images and i18n targets make sure that various images
and properties files get into the correct locations in $(CLASSDIR).
The ‘%.class: %.java’ target is the one which compiles the code.
Eclipse, vim, emacs, whatever gets the job done fastest. Eclipse has some very nice refactoring utilities. Vim is great for processing text files in arbitrary ways. Emacs is more lightweight than Eclipse but has a nice interface.
For newbies, Eclipse is the way to go. But the SVN interface is terrible–I never did figure that out.
Joel, what shell are you using? I always have to add SHELL:=bash in the Makefile because you use brace expansion which is not compatible with the default shell (/bin/sh). Perhaps that could just be added to the Makefile?
On Mon, March 17, 2008 4:17 pm, Michael Kiefte wrote:
It’s definitely a Debian default. I’m fairly sure I’ve seen it on plenty
of other distributions - the “why do my Linux /bin/sh scripts (full of
bash-isms) not work on other Unices?” question shows up on forums and
mailing lists with alarming regularity.
I can see the argument for not making sh be bash, for backwards
compatibility with places where it isn’t. The thought of doing anything
extensive (interactive or scripted) in these enlightened days, with raw sh
gives me the heebie-jeebies, resources usage be damned.
I use bash. It didn’t occur to me that I should set the shell explicitly.
I’ll add that this evening. (This means that make’s default shell is
not the same on my system as on yours.)
I am not sure why you are hand-editing the buildfile instead of just creating the Tabbed Maps using the editor?
Is it because you want to move existing maps into a tabbed pane and the cut & paste doesn’t work? If so, then I suggest you create the new structure you want with temporary maps so that the buildfile gets created correctly. Then hand edit and carefully replace the data for the new VASSAL.build.widget.WidgetMap’s with the old VASSAL.build.module.Map’s. (Only WidgetMap’s may exist within a MapWidget).
In general, hand-editing of the buildfile is frought with dangers and you MUST know what you are doing. It is not a ‘supported’ method of editing a module, though some information on how to do it successfully is around. A flood of Exceptions indicates that you have made a mistake.
To put the hand-editing issue to an end: its nothing else than with the editor, as long as you produce valid XML. The editor is doing nothing more…prop. utililizing a SAX engine. Anyways, what i did can be produced with the editor as well. Just make up a fresh module, put a chart with a tabbed pane and some maps (WidgetMap) in. Then delete the Map that is predefined (MapWindow). This saves without an error (valid XML). But produces lots of exceptions on a low AWT.draw.something-leve…with leads to the conclusion that this is simply not implemented atm. The module will load, create a chat view and a grey area, but is unable to create anything beyond that point.
I see its missing functionality, its ok, Joes mentiont this to be functional for an upcomming release.
JAVA IDEs
Well i think eclipse is a pharse…i do not like it at all. I am used to writing C/C++ code a lot using an editor and compiling via shell. Glad to hear thats working out for java as well. NETBEANs doesnt do the job for me either. I’d like to have a system i can use on linux (At home) and win(at work)… any vim4win or something similar available?
I can’t offer any advice about how best to set up to compile on Windows,
though. Maybe you could set up Ant? (I don’t like Ant’s syntax, I find
it too verbose, which is why I use Makefiles—but many people do like
it and use it as their build environment.)
When I was a young software engineer, we used to dream of programming environments that did half of what modern IDE’s do. I remember writing some stuff in Lisp under EMACS to help with FORTRAN programming!
What are your problems with Eclipse? Is it setting up the build configurations and getting Vassal runnning? Or the SVN interface? I’m happy to help you sort them out. I don’t understand how Joel does without it I really couldn’t live without the intergrated debugger and the contextual searching.
no problems realy, just that i dont feel comfortable with it. it wont offer much beyond any combination of powerfull editor + dev tools that i have spotted so far. also i find its annoying how you change to an new ide and it comes with thousands of reinventions of the wheel in green red and blue, and how you have to use their plugins if you dont want to waste further time pluging your tools in. but i guess thats just me…
i had no problems setting up eclipse, im new to the svn though. used to have cvs.
i have all svn running but a short version (not that how to fix a warp engine one ) of the traps and pitfalls would be nice. although im currently reading on that topic
think im good to go by eastern, will let you know…