Page 3 of 4
Re: The Geyser Layout Manager
Posted: Sun Apr 24, 2011 8:28 pm
by Vadi
Mind adding some examples for this?
Re: The Geyser Layout Manager
Posted: Sun Apr 24, 2011 10:20 pm
by Beliar
Well, lets see.
You have a image "ui_top.png" with a size of 129x12. You wanted that tiled horizontally.
Like this: ------------------------------------
The following code creates an window with the image tiled horizontally over that:
Geyser.TiledImage:new({
name="ui_top",
x="0px", y="0px",
width="100%", height=12
tile_image="ui_top.png", -- This is the path to the image
tile_width=129, --Width of a single tile
tile_height=12, --Height of a single tile
}
Next, you want an image tiled vertically:
Like this:
|
|
|
|
|
Geyser.TiledImage:new({
name="ui_left",
x="0px", y="0px",
width=12, height="100%"
tile_image="ui_left.png", -- This is the path to the image
tile_width=12, --Width of a single tile
tile_height=129, --Height of a single tile
tile_alignment=Geyser.TileAlignment.vertical --Tells the class to tile vertically. It defaults to horizontal.
}
Now you want to have another image(s) at the start/end of the window.
Like this : (-------------------------------)
Geyser.TiledImage:new({
name="ui_bottom",
x="0px", y="0px",
width="100%", height=12
tile_image="ui_bottom.png", -- This is the path to the image
tile_width=129, --Width of a single tile
tile_height=12, --Height of a single tile
start_tile_image = "ui_bottom_left.png", -- Path to the image of the start tile
start_tile_wdith = 50, -- Width of the start tile
start_tile_height = 12, -- Height of the start tile
end_tile_image = "ui_bottom_right.png", -- Path to the image of the end tile
start_tile_wdith = 30, -- Width of the end tile
start_tile_height = 12, -- Height of the end tile
}
Hope that helps.
Re: The Geyser Layout Manager
Posted: Wed Apr 27, 2011 1:05 pm
by Beliar
I found an easier way if you just need a single image tiled on a label:
setStyleSheet("background-image: url(" .. imageFileName .. ");")
Re: The Geyser Layout Manager
Posted: Thu May 05, 2011 7:15 am
by Beliar
I have made some additions to Geyser:
- Removed TIledImage
- Added setTiledBackgroundImage method to Geyser.Label, which does (mostly) the same as TiledImage, only its faster
- Added classes to align windows horizontally or vertically and automatically stretching them to fit.
- Added simple Manual/Tutorial for Geyser.
- Geyser uses registerAnonymousEventHandler to automatically register itself to sysWindowResizeEvent
[edit]
Note: These need Mudlet 2.0rc3
[/edit]
I hope these will be added to mudlet, but if you want to test them first you can download them here:
https://github.com/Beliaar/mudlet-lua/downloads
Download on the files listed under "Download Packages"
Just replace the mudlet-lua directory in your mudlet directory with the directory in the download, maybe backing up your directory before.
The manual is in the geyser directory as a html file.
Re: The Geyser Layout Manager
Posted: Thu May 05, 2011 8:27 pm
by Vadi
I don't think keeping the Geyser manual separate is a good idea, or one that users will like. Can you please see about moving it to
http://wiki.mudlet.org/w/Category:Mudlet_Manual instead?
Re: The Geyser Layout Manager
Posted: Fri May 06, 2011 6:27 am
by Beliar
I never intended it to be separate - it uses the same CSS as the mudlet manual after all, and I didn't know that there was a page for that in the wiki. I will see what I can do to add that there.
Edit:
http://wiki.mudlet.org/w/Manual:Geyser
Re: The Geyser Layout Manager
Posted: Fri May 06, 2011 8:13 am
by Vadi
cool, thanks!
Re: The Geyser Layout Manager
Posted: Sun Jan 19, 2014 12:32 am
by Akaya
Can Geyser.Gauge fill from right to left instead of left to right?
Re: The Geyser Layout Manager
Posted: Sun Jan 19, 2014 2:29 am
by Jor'Mox
Yes, use the "goofy" style where you would normally use "vertical" or what have you. The newer gauges that I designed do the same, and I believe they are being incorporated with the next release as the default gauges, just FYI.
Re: The Geyser Layout Manager
Posted: Sun Jan 19, 2014 3:25 am
by Akaya
ah. Didn't even know orientation was an argument. Thanks!