phantomwhale
November 7th, 2010, 21:15
I have been looking into fixing a problem that manifests in multiple places in the Savage Worlds ruleset, namely when you have a skill name that is too long in the NPC or PC sheets, then the dice and string box to the right hand side can become impossible to select / drag from or drop to.
E.g. create a new NPC in Savage worlds. Give him two skills, one called aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa and once called bbbbbbbbbbbbbbbbbbbbbb. Now try and select the dice or edit the name of the second skill - you won't be able to. Also, when right-clicking to delete a right hand element, you will remove the left hand element, as this it's "Zone of control" has overshot the displayed boundaries.
Distilling this down to get to the root cause, it seems built into the core windowlist rendering somehow. Creating a mocked up basic 2 column window list with a simple string entry field, I recreated this problem.
Of course, looking around for how this might be overcome in the 4E / 3.5E rulesets, I found out - they don't use multi-column windowlists ever !
Below is the code fragments of the mockup window list I was experimenting with, complete with all my odd attempts at curtailing the "zone of control" from going outside the column :
<windowclass name="basicentry">
<size>
<width>120</width>
</size>
<sizelimits>
<minimum>
<width>120</width>
<height>20</height>
</minimum>
</sizelimits>
<sheetdata>
<stringfield name="name">
<bounds>5,0,115,20</bounds>
<font>sheettext</font>
<frame>
<name>textline</name>
<offset>2,0,2,0</offset>
</frame>
</stringfield>
</sheetdata>
</windowclass>
<windowlist name="basiclist">
<anchored>
<left>
<anchor>left</anchor>
</left>
<top>
<anchor>top</anchor>
<offset>35</offset>
</top>
<size>
<width>240</width>
</size>
</anchored>
<columns>
<width>120</width>
<fillwidth />
</columns>
<class>basicentry</class>
<datasource>.entries</datasource>
<allowcreate />
<allowdelete />
<script>
function onInit()
createWindow()
end
</script>
</windowlist>
E.g. create a new NPC in Savage worlds. Give him two skills, one called aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa and once called bbbbbbbbbbbbbbbbbbbbbb. Now try and select the dice or edit the name of the second skill - you won't be able to. Also, when right-clicking to delete a right hand element, you will remove the left hand element, as this it's "Zone of control" has overshot the displayed boundaries.
Distilling this down to get to the root cause, it seems built into the core windowlist rendering somehow. Creating a mocked up basic 2 column window list with a simple string entry field, I recreated this problem.
Of course, looking around for how this might be overcome in the 4E / 3.5E rulesets, I found out - they don't use multi-column windowlists ever !
Below is the code fragments of the mockup window list I was experimenting with, complete with all my odd attempts at curtailing the "zone of control" from going outside the column :
<windowclass name="basicentry">
<size>
<width>120</width>
</size>
<sizelimits>
<minimum>
<width>120</width>
<height>20</height>
</minimum>
</sizelimits>
<sheetdata>
<stringfield name="name">
<bounds>5,0,115,20</bounds>
<font>sheettext</font>
<frame>
<name>textline</name>
<offset>2,0,2,0</offset>
</frame>
</stringfield>
</sheetdata>
</windowclass>
<windowlist name="basiclist">
<anchored>
<left>
<anchor>left</anchor>
</left>
<top>
<anchor>top</anchor>
<offset>35</offset>
</top>
<size>
<width>240</width>
</size>
</anchored>
<columns>
<width>120</width>
<fillwidth />
</columns>
<class>basicentry</class>
<datasource>.entries</datasource>
<allowcreate />
<allowdelete />
<script>
function onInit()
createWindow()
end
</script>
</windowlist>