STAR TREK 2d20
  1. #1

    Changing a 4E Skill windowlist window to not custom

    I am trying to make skills in the 4E ruleset be in sub-groups of a parent skill (at least in presentation in the skill page windowlist) So in record_char_skills.xml, I have C+P the label control that is the name of the skill, and renamed it label1 and increased the left offset to indent it from the rest of the skills. Then in the char_skilllist.lua file I give the skill name to the label1 control (same as label has) and then set label to invisible, and make labal1 disabled... It works, but the newly visible label1 field is both underlined, and the window (windowlist object) is set to custom and I can't figure out how to set it back... Tried match.setCustom(false);

    Here's the change I made to record_char_skills.xml
    Code:
    			<stringu name="label">
    				<anchored height="20">
    					<top offset="2" />
    					<left offset="25" />
    					<right parent="rightanchor" anchor="left" relation="relative" offset="-5" />
    				</anchored>
    				<tabtarget next="misc" />
    			</stringu>
    
    			<stringu name="label1">
    				<anchored height="20">
    					<top offset="2" />
    					<left offset="40" />
    					<right parent="rightanchor" anchor="left" relation="relative" offset="-5" />
    				</anchored>
    				<tabtarget next="misc" />
    			</stringu>
    and here's the change I made to char_skilllist.lua

    Code:
    		-- Update properties
    		local bCustom = false;
    		for _, match in pairs(matches) do
    			match.setCustom(bCustom);
    			if not bCustom then
    				if t.stat then
    					match.statname.setStringValue(t.stat);
    				else
    					match.statname.setStringValue("");
    				end
    				if t.sort then
    					match.spec.setValue(t.sort);
    					match.label1.setValue(k);
    					match.label1.setVisible(true);
    					match.label1.setEnabled(false);
    					match.label.setVisible(false);
    					match.setCustom(false);
    				else
    					match.spec.setValue(k);
    				end
    				
    			else
    				match.statname.setReadOnly(true);
    			end
    			bCustom = true;
    		end
    What am I missing about setting the windowlist window back to not custom, or if there isn't an easy way to do that, is there a better way to indent the label field in record_char_skills.xml or finally am I barking up the wrong tree and there's a better way to catch this particular squirrel?

    TIA

  2. #2
    Ok, nevermind all of the above. I got the altered list elements to go back to not custom... unfortunately I still can't get the underline to go away.

    So now the question is just how do I get rid of the underline in a stringu control?

  3. #3
    NM... .setLine(false);

    all is well... nothing to see here.

  4. #4
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,361
    Quote Originally Posted by Hornet View Post
    So now the question is just how do I get rid of the underline in a stringu control?
    The u in stringu stands for underline. Try changing the stringu template to simplestring - the control is similar, but removes the underline and adds a drop type of string - I don't know if the drop type will be an issue for you.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  5. #5
    Thanks! I was wondering about that. There isn't a template for it (though it is used to build the string_ps template) in the 4E ruleset, and the dev wiki doesn't have any info on it.

  6. #6
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,361
    Quote Originally Posted by Hornet View Post
    Thanks! I was wondering about that. There isn't a template for it (though it is used to build the string_ps template) in the 4E ruleset, and the dev wiki doesn't have any info on it.
    The 4E ruleset is layered on top of the CoreRPG ruleset and uses a lot of templates from there. stringu and simplestring are both in the common\template_common.xml file in the CoreRPG ruleset. It takes a little bit of getting used to - having to do a "find in files" in both the 4E and CoreRPG ruleset to find templates and windowclass entries.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  7. #7
    Ahhh! I knew that! lol... Thanks for the rap on the head. /em looks sheepish.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
DICE PACKS BUNDLE

Log in

Log in