[crossfire] GTK2-v2 Client new layout defined

Mark Wedel mwedel at sonic.net
Tue Jul 31 00:24:29 CDT 2007


Kevin R. Bulgrien wrote:
> Lalo Martins wrote:
> 
>> A discussion we had a while ago when the v2 client first appeared:
>>
>> Many laptops on the market today aren't able to do more than 1024x768,
>> and that isn't about to change any time soon.
>>
>> I *normally* play on my PC, but if I ever became unable to play on the
>> laptop, I would be very disappointed.
> 
> The biggest challenge there is that the v2 client appears to use a
> system defined font, so unless that font is pretty small, the v2 client
> cannot be as tight as the v1 GTK client.

  Does the gtk1 client actually specify a font to use?  I thought that also used 
the system font.

  In any case, the gtk2 client also supports themes, so it is certainly possible 
to make a custom theme that uses a different/smaller font file.

  Now it would start to be a little goofy to be playing with both the them and 
font to try and get something that works.  OTOH, these are really two separate 
things - window layout and text size is really independent.

  Note that the main reason the gtk1 client can fit more in smaller space is 
that it defaults to an 11x11 map size.  So out of the box, that effectively 
gives a lot more space to things like the text window, inventory, stats, etc. 
But IMO, it also de-emphasizes the map a bit - the total space used by the map 
is very little compared to all the rest of the information.

  That said, there has been some suggestions about features to make things more 
usable.  One which I haven't done yet is something like quick apply areas.

  Take a little screen place someplace, and have something like 5-10 spaces for 
icons.  Let players drag and drop stuff from their inventory to these icons - 
these then become fast apply areas - you click on that icon, and whatever that 
item is is applied (be it potion, weapon, armor).  Perhaps also assign them 
numbers (0-9), and with control-0 or something, it also applies it.

  If this was done, then during normal exploration of a dungeon, the player 
probably wouldn't need the inventory area anymore.  I could be wrong in this, 
but my experience is that I need to access a few items in my inventory (switch 
weapons, drink a potion, etc) - I probably don't need more than 10.

  But if inventory was hidden (perhaps by a tab), that frees up a lot of space 
for other information.  Note that even with this, the look (on the ground) would 
still need to be displayed.

  It'd be even cooler to be able to drag spells into that area, so you have fast 
apply of spells also.


> I mentioned as much on IRC... yes, libglade would be neat.  I'd have to
> get a lot more comfortable with Glade and the client code to try it
> myself.  (I was able to do the re-layout without touching any of the
> client code.)  I think, though, unless it was easy, it seems there may
> be better things to do than convert the client to use libglade.  It's
> not like you have a lot of options on layout unless you have an obscenely
> large display - and that's not a problem I have, and it doesn't seem to
> be a problem a lot of players have.

  If need help, I could also look at the libglade stuff.

  Now as person with an obscenely large display, I find the default gtk2 client 
works just fine.  But would be curious what improvements could be done - but to 
be honest, I tend to run it at roughly the 1280x1024 resolution - that just 
gives me room to have other windows up and about.

  The real advantage of libglade is that it then makes it very easy for anyone 
to be a tinkerer - anyone with some proficiency in libglade can go about and try 
moving things about, and not have to worry about needing to recompile, etc. 
There is a non trivial number of people that download the precompiled packages - 
OTOH, I have no idea how many of those would then try to go about playing with 
glade files.

> 
>> Of course, my preference would be for using a widget similar to the
>> Gimp's dockable panes, so an user can change the layout at runtime.  But
>> I looked around and found no such widget in a library format.

  At one point, that was the reason for the gnome client - the sub windows were 
tearaway, so you could pull one off, put it elsewhere, etc.

  I don't see that functionality in glade - doesn't mean that those widgets 
don't exist, but there is some amount of stuff that requires extra work to do.

  I know it has also been suggested that there be a split window mode - I think 
the only thing to do that would be to remove the root window and make sub 
windows for all the other stuff.  But I'm sure there is some stuff that presumes 
that window_root actually exists, and that the other windows are children off 
it.  Making window_root exist would be easy - if some code requires that 
heirarchy, that is a problem.

  Also, with the gtk2 client (compared to the X11 client), some window still has 
to be nominated as the main/root window - need someplace to put the menubar. 
X11 client doesn't have a menubar.



More information about the crossfire mailing list