Page 2 of 2

Re: Requests/Bugs

Posted: Tue Jun 15, 2010 1:38 pm
by Vadi
Calculatable dimensions... for example, height = "100% - 50px". I have a box I need to stretch depending on the screen size, but it has static elements both below and above it; and I need it to fit in between.

I guess this resembles something like so: http://hacks.mozilla.org/2010/06/css3-calc/

Re: Requests/Bugs

Posted: Tue Jun 15, 2010 10:33 pm
by naftali
agreed. I use the Geyser.Container:get_width() and such functions for that purpose, but it'd be nicer if you could do that instead.

Re: Requests/Bugs

Posted: Mon Sep 27, 2010 5:24 pm
by Vadi
One more... seems the setLabelStyleSheet function needs to be hooked up, so you can do <label object>:setLabelStyleSheet(css).

Current workaround of setLabelStyleSheet("<label object name>", css) works. Anyone up for adding this simple thing?

Re: Requests/Bugs

Posted: Sun Apr 24, 2011 10:29 am
by Beliar
Here the style sheet method(s) as requested:

Label:
Code: [show] | [select all] lua
--- Sets the style sheet of the label
-- @param css The style sheet string
function Geyser.Label:setStyleSheet(css)
	setLabelStyleSheet(self.name, css)
end
Gauge:
Code: [show] | [select all] lua
-- Sets the style sheet for the gauge
-- @param css Style sheet for the front label
-- @param cssback Style sheet for the back label
function Geyser.Gauge:setStyleSheet(css, cssback)
	self.front:setStyleSheet(css)
	self.back:setStyleSheet(cssback or css)
end
Just put them in appropiate positions in GeyserLabel.lua and GeyserGauge.lua and restart Mudlet.

Note that the gauge builds on the label having the method added.

Re: Requests/Bugs

Posted: Sun Apr 24, 2011 4:52 pm
by Vadi
Thanks a ton!

Re: Requests/Bugs

Posted: Thu May 19, 2011 6:51 am
by demonnic
Found a bug when creating new miniconsoles. They don't set their fontSize. I -think- just adding this at line 107 of GeyserMiniConsole.lua will fix it, but if I'm way off base let me know:
Code: [show] | [select all] lua
  if cons.fontSize then
    me:setFontSize(cons.fontSize)
  else
    me:setFontSize(8)
  end

I took the line number from the file at your github account, Beliar. I put the else in because miniconsoles -really- don't work very well if they don't have their font size set. It's possible you may want to grab the value from the parent, rather than defaulting to 8. I didn't look into the code quite deeply enough to see how to go about that though.

Re: Requests/Bugs

Posted: Thu May 19, 2011 7:05 am
by Beliar
Ok, I'll added that code with a minor modification:
Code: [show] | [select all] lua
   if cons.fontSize then
      me:setFontSize(cons.fontSize)
   elseif container then
      me:setFontSize(container.fontSize)
   else
      me:setFontSize(8)
   end

Re: Requests/Bugs

Posted: Thu May 19, 2011 1:37 pm
by demonnic
Awesomesauce. Thanks!

Re: Requests/Bugs

Posted: Mon May 30, 2011 5:56 pm
by Vadi
Is it possible to bring all of the API documentation for Geyser in http://wiki.mudlet.org/w/Manual:Geyser? So it'll become *the* place for all Geyser things to link to / learn.

Re: Requests/Bugs

Posted: Mon May 30, 2011 6:02 pm
by demonnic
sent a pull request from my branch to include Geyser.MiniConsole:append() and Geyser.MiniConsole:clear() in order to get appendBuffer and clearUserWindow() functionality with the Geyser auto-named miniconsoles. I found with my tabbed chat, and last night while working on porting my lusternian calendar that I was having to give my miniconsoles names anyways. This should let Geyser handled all of that.