Jump to content

[Help] guiSetSize of a label.


roaddog

Recommended Posts

Posted (edited)

So I got a label which is in a scrollpane, and This label is gonna be filled by a txt file which has many lines.

and then I place it, but The text didn't really fill them up, the buttom just get wrapped out.

See this picture if you dont get what I mean by wrapped out.

c68abbac8f.png

You see it, the text isnt really finished. I need to calculate it, and then the offset will be used to set the size of it.

Thankee.

Edited by Guest
Posted

Oh alright then.

-- Vehicle Commands 
/engine - Turn your engine on or off. 
l 
/lock - Lock your vehicle. 
/unlock - Unlock your vehicle. 
/fp - Toggle first person view. 

hey so this is pretty much the txt file. how do I split it by lines?

Posted

Yes. due to the height's of label cant go highter than 600, I need to split the file into tables by lines. and make a label for each lines, is that alright?

Posted

Please, Anyone?

I know how to seperate a string into a table by space.

to seperate a string by new lines, how to do that, what is the character class?

s = "hello world from Lua\n Another line, I believe" 
 for w in string.gmatch(s, "%a+") do 
 print(w) 
 end 

Posted
s = "Hello|World" 
table = split(s, "|") 
for placeNumber, stringData in ipairs(table) do 
    outputChatBox(stringData) 
end 

*cough* edited

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...