ID:75927
 
Not a bug
Not a bug
BYOND Version:444
Operating System:Windows Vista Home Premium
Web Browser:Firefox 3.5
Status: Not a bug

This is not a bug. It may be an incorrect use of syntax or a limitation in the software. For further discussion on the matter, please consult the BYOND Developer forums.
A third pane-child bug, I'm on a roll!

In my Skin Input library that I'm working on, I noticed an even stranger bug than all my previous ones; can-scroll and size behaving strangely.

EDIT:

The following snippet:
    proc/Set_pane(client/owner,size="0x0")

var/list/params = new
// params["can-scroll"] = "both" can-scroll can't be changed at runtime, apparently
params["is-visible"] = "true" //just in case
params["size"] = size
world << size
params["background-color"] = PromptMaster.bg_color //once again, just in case

winset(owner,"JPromptPane-[owner.computer_id]",params)

return "JPromptPane-[owner.computer_id]"


Will not work, whereas the following will:

    proc/Set_pane(client/owner,size="0x0")

var/list/params = new
// params["can-scroll"] = "both" can-scroll can't be changed at runtime, apparently
params["is-visible"] = "true" //just in case
params["size"] = size
world << size
params["background-color"] = PromptMaster.bg_color //once again, just in case

winset(owner,null,"JPromptPane-[owner.computer_id].is-visible=true;JPromptPane-[owner.computer_id].size=[size];JPromptPane-[owner.computer_id].background-color=[PromptMaster.bg_color];")

return "JPromptPane-[owner.computer_id]"


EDIT #2: Fixed typo, the second arg for winset() in the second snippet should have been null.
The winset() isn't failing due to a bug. It's failing because you never told it what parameter to set. Specifically, you're sending "244x150" instead of "size=244x150" in winset, so DS thinks you're trying to set a parameter named "244x150" to an empty value.
Lummox JR wrote:
The winset() isn't failing due to a bug. It's failing because you never told it what parameter to set. Specifically, you're sending "244x150" instead of "size=244x150" in winset, so DS thinks you're trying to set a parameter named "244x150" to an empty value.

Ah, that was rather stupid of me. However, I found the source of the original issue. For some reason, the pane won't respond to one format of winset(), but it responds to another. I'll edit my post for it in a moment.
This is still not a bug. Your winset() call is failing because you're passing an actual list for params instead of the list2params() form.
Lummox JR wrote:
This is still not a bug. Your winset() call is failing because you're passing an actual list for params instead of the list2params() form.

Oh, wow, more stupidity. Sorry, I'm pretty tired today, I'll stop >_>
Eh, you're not the only one who had trouble spotting it. On first glance many of the issues don't really look like problems at all. I only noticed the list thing because while I was tracing through I found the client was getting a winset with 0 parameters.