Thread: Ruleset ignoring XML parameters
-
April 2nd, 2008, 17:35 #1
- Join Date
- Feb 2007
- Posts
- 50
Ruleset ignoring XML parameters
I'm trying to make a mini-sheet, and so far everything has worked well, except for this one bug which seems to be entirely arbitrary. I've created a basic frame, and set its bounds in relation to the minisheet. To that frame, I've anchored a modifier number.
For some unknown reason, FG is ignoring the <height></height> parameter for that number's frame. It accepts the width, but not the height. And it only does this when I anchor the number control to that generic frame. I have checked, rechecked, and triple checked my XML syntax. I'm pretty sure the problem is not there, but I have no idea where else it could be, because there are no scripts linked to these elements.
When I run the code, I get a console error that says "Ruleset Warning: Anchored control static height ignored" (in orange text if that matters).
Here's the code. The element being ignored is in bold. Any help would be appreciated.
Code:... <sheetdata> <labeledstring name="name"> <bounds>15,25,120,20</bounds> <label>name</label> <static /> </labeledstring> <genericcontrol name="combatframe"> <bounds>10,50,275,121</bounds> <!-- <frame> <name>modifier</name> </frame> --> </genericcontrol> <genericcontrol name="initiativeframe"> <bounds>125,15,100,30</bounds> <frame> <name>modifier</name> <offset>5,5,5,5</offset> </frame> </genericcontrol> <ministaticmod name="initiative" source="initiative.total"> <description> <text>Initiative</text> </description> <anchored> <to>initiativeframe</to> <position>insideright</position> <offset>3,5</offset> <size> <width>30</width> <height>20</height> </size> </anchored> </ministaticmod> <stringcontrol> <anchored> <to>initiative</to> <position>left</position> <offset>5,-3</offset> </anchored> <static>Initiative</static> <font>sheetlabel</font> </stringcontrol> ...
-
April 2nd, 2008, 17:59 #2
Should the size controls be within the anchored tags?
** edit **
Please ignore. I was having a blond moment.
-
April 2nd, 2008, 19:33 #3
The template doesn't include <anchored> and/or the inner <size> node does it?
It could be a problem with the merge rules. If it does include those nodes try using the replace mergerule in the template (i.e. <anchored mergerule="replace">)Work Less, Game More!
-
April 2nd, 2008, 20:02 #4
- Join Date
- Feb 2007
- Posts
- 50
I think I might have figured it out. It seems like all the center point anchors ignore one size parameter. Anchoring to a corner rather than "insideright" makes it consider the height parameter again. All the center point anchors seem to want an offset for at least one of their size parameters.
-
April 3rd, 2008, 19:24 #5
Ah yes. I invariably fall back to using the more simple form:
Code:<anchored> <left> <parent>label</parent> <anchor>right</anchor> </left> <top> <anchor>top</anchor> <offset>5</offset> </top> <size> <width>30</width> <height>22</height> </size> </anchored>
Work Less, Game More!
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks