newlayer = insertlayer(NIL,...) how does it work?
Posted: Fri Aug 27, 2010 5:24 pm
I couldnt find it from manual by quick look, but if i correctly remember, since Hollywood4.5 or soemthing we hadnt had need to worry about next free layers number anymore.
I think it was something like this:
newlayer = InsertLayer(NIL, #BRUSH, brushnumber, x, y)
setlayername(newlayer, "name")
Point was that when you put layers number as NIL, then it would simply assign next free layer number to the layer and return its value.
However, at least when i do it this way, it doesnt work.
So anyone knows how it worked?
Also, is there possibility to set the name of Layer instantly someway, in way of:
InsertLayer(NIL, #BRUSH, brushnumber, x, y, { name="name" })
Its possible to do with TextOut() - command this way, but as far as i remember, it havent worked in this InsertLayer() - command.
I think it was something like this:
newlayer = InsertLayer(NIL, #BRUSH, brushnumber, x, y)
setlayername(newlayer, "name")
Point was that when you put layers number as NIL, then it would simply assign next free layer number to the layer and return its value.
However, at least when i do it this way, it doesnt work.
So anyone knows how it worked?
Also, is there possibility to set the name of Layer instantly someway, in way of:
InsertLayer(NIL, #BRUSH, brushnumber, x, y, { name="name" })
Its possible to do with TextOut() - command this way, but as far as i remember, it havent worked in this InsertLayer() - command.