STAR TREK 2d20
Page 1 of 3 123 Last
  1. #1
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075

    Anchor takin' me down...

    So, I am just about done - spent some time rearranging and decided to shrink the middle of the (working) attrbis number boxes section and move the (working) saving throw boxes to upper right.

    So, as usual I toss up some guesstimates to see where it puts me before I minimal until like I want it.
    But using the anchor vs position anchoring has never given me an issue like this. I suspect it is somehow related to something different about "the anchoring will be done to the window edges." part. But I thought it made sense and I grokked it. But nope.

    See below:

    Code:
    			<!-- Saving Throws -->
    			<label name="savingthrow_label">
    				<anchored height="25">>
     					<right parent="" anchor="right" offset="-15" />
    <!--					<left parent="" anchor="right" offset="-15" /> -->
    					<top parent="attributeframe" />
    				</anchored>
    				<multilinespacing>12</multilinespacing>
    				<static textres="char_label_savingthrows" />
    			</label>
    Attached is pics of how it appears based on above and above when I comment right and uncomment left...

    I EXPECTED the first one to be what I wanted. (Hmm will remove multiline to see if affects this - have to go put kid to be first though, then TWD)

    Right-Right.jpeg
    Left-Right.jpeg

    Any clue?

  2. #2

  3. #3
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    attribute bonuses are mainly setup with to/position setups once the initial key attribute (to hit) is setup within the attribute frame.

    The saving throws, as might be inferred from the small excerpt is intended to be bound to right edge (with 15 pixel offset) so as to hug that edge.

    I wanted that vs off the attributes bonus frame for a reason likely not worth explaining (part of it amounts to learning) yet. Let’s pretend I was starting with this label and I wanted it to be anchored to right edge of character sheet and below the “Race” line above it.

    How could I get that to work using <top> plus <right> or <left> tags plus attributes (parent/anchor/offset)?

  4. #4
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    26,685
    Blog Entries
    1
    Sorry I thought it was the word Saving Throws that wasnt right (its not!!!).

    Have a look at Inventory sheet and see how that is done.

  5. #5
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    26,685
    Blog Entries
    1
    But the reality is - these are 6 static values. There will always be 6, no more, no less, and they will always be in teh same place.
    Just code them absolutely.

  6. #6
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    I’ll look in morning (in bed atm) not sure what mean by inventory sheet... CoreRPG/MoreCore? Also, not sure what six values we are speaking of? At least unless change layout again, will be having 6 numeric boxes that will be rollable below that “Saving Throws” label in a single column.

    I don’t use absolute placement anywhere on my sheet as of yet, instead it’s done with anchoring.

    it’s really late and I probably just don’t get what you are telling me (eso since haven’t looked for the inv sheet) but I really figured this would be obvious from the anchoring wiki. Set my right edge of the label to the right edge of the window and put and offset to make it not be on the edge.

    But I guess I don’t know how to write that?

  7. #7
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    Oh, one more thing... didn’t feel it germane but rereading saw “they will always be in the same place” - actually I will have at min 2 and possibly 3 layouts on that right edge based on DM options.

    But again, was just asking in vacuum how to pin it to a right edge with single edge anchors.

  8. #8
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    26,685
    Blog Entries
    1
    Quote Originally Posted by Varsuuk View Post
    Code:
    			<!-- Saving Throws -->
    			<label name="savingthrow_label">
    				<anchored height="25">>
     					<right parent="" anchor="right" offset="-15" />
    <!--					<left parent="" anchor="right" offset="-15" /> -->
    					<top parent="attributeframe" />
    				</anchored>
    				<multilinespacing>12</multilinespacing>
    				<static textres="char_label_savingthrows" />
    			</label>
    Look in the C&C ruleset.
    They have used

    Code:
    			<string_charabilitylabel name="strength_label">
    				<anchored to="strength" />
    				<static textres="strength" />
    			</string_charabilitylabel>
    and
    Code:
    	<template name="string_charabilitylabel">
    		<label>
    			<anchored position="lefthigh" width="85" height="20" />
    			<static />
    			<disabled />
    			<tooltip  />
    		</label>
    	</template>

  9. #9
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    Yes, those work fine. If I wasn’t on my train, I’d post the way did the abilities and would match that (ie using to & position)

    I’m trying to find out why the top/bottom/left/right method is not working for me with parent=“” (the window)

    i’m stumped. Those two you linked avoid the issue. I bet if I did to=“racesomethingstring” position=“bottomright” and a horiz,vertical offset it would work since I don’t reference window. And in the end, will probably go that route in any event once I learn about this. It’s just that I hate to leave gaps when I try to do something and it fails, I want to understand it.

    There’s something I am doing wrong or there is a weirdly (unlikely) unreported bug in wiki anchor instructions. When I get home from work will try grepping for anchor=right or left where parent=“” which may never appear due to parent=“” is equivalent of not supplying parent at all. But that’s my next step if no clues.

  10. #10

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
  •  
5E Product Walkthrough Playlist

Log in

Log in