function GetRoomExits()
roomexits = nil
for i,v in pairs(gmcp.Room.Info.exits) do
if not roomexits then
roomexits = string.upper(i)
else
roomexits = roomexits..","..string.upper(i)
end
end
roomexits = roomexits or "TRAPPED!"
roomlabel: setFgColor("red")
roomlabel:echo("Exits - <br>" ..roomexits, nil, "c")
roomLabel.front:setStyleSheet([[background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ADADAD, stop: 1 #9E9E9E);
border-top: 1px black solid;
border-left: 1px black solid;
border-bottom: 1px black solid;
border-radius: 7;
padding: 3px;
]])
roomLabel.back:setStyleSheet([[background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #575757 stop: 1 #454545);
border-width: 1px;
border-color: black;
border-style: solid;
border-radius: 7;
padding: 3px;
]])
end
roomlabel = Geyser.Label:new({name="Room Exits",x=1200, y=410,width=150, height=30,})
roomlabel : setFgColor("red")
registerAnonymousEventHandler("gmcp.Room.Info", "GetRoomExits")
Why isn't this working. It makes the label but....
-
- Posts: 9
- Joined: Sat Sep 25, 2010 5:47 pm
Why isn't this working. It makes the label but....
It makes the label but it doesn't apply the style sheets... been working on my gui for 2 days now and it's given me the biggest headache ever
Last edited by Oneymus on Mon May 26, 2014 3:15 am, edited 1 time in total.
Reason: Added Lua tags. Please, for the love of those helping you, format your code and use the tags.
Reason: Added Lua tags. Please, for the love of those helping you, format your code and use the tags.
Re: Why isn't this working. It makes the label but....
Two reasons I can think of - first, capitalization matters (roomLabel vs. roomlabel). Second, aren't the .front and .back styles only for gauges?