![](/images/style_mmoi_eq2i/layout/clear.gif) |
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-16-2010, 02:45 PM
|
![Jamesc146's Avatar](image.php?s=c7593d4545cff0da91d4432063400585&u=271694&dateline=1253772615) |
A Griffon
|
|
Join Date: Nov 2008
Server: Butcherblock
Posts: 101
|
|
Tradeskill window
<Button IsDefaultButton="true" Location="312,520" MinimumSize="10,10" Name="Repeat" PackLocation="right,bottom" ScrollExtent="42,42" Size="42,42" Style="Styles.Repeat.style" Visible="false" />
<Button IsCancelButton="true" Location="312,520" MinimumSize="10,10" Name="Stop" PackLocation="right,bottom" ScrollExtent="42,42" Size="42,42" Style="Styles.Stop.style" />
Would changing the red above to be the following move the repeat button to the center instead of being right over the stop button?:
<Button IsDefaultButton="true" Location="???,520" MinimumSize="10,10" Name="Repeat" PackLocation="center,bottom" ScrollExtent="42,42" Size="42,42" Style="Styles.Repeat.style" Visible="false" />
|
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-18-2010, 05:40 PM
|
![EQAditu's Avatar](image.php?s=c7593d4545cff0da91d4432063400585&u=30990&dateline=1178591966) |
A Griffon
|
|
Join Date: Mar 2005
Server: Permafrost
Posts: 256
|
|
Pack locations refer to how an control will move its own location in relation to it's parent's bounds. Though I cannot say that I understand what "right,bottom" would mean because that doesn't follow the format the UI builder documentation specifies. It leaves out information and uses different keywords.
If you wanted a button to remain centered near the bottom within a resizable window, you could use "CPC,FFF". I think. This is sort of going off of memory of how it works.
It stands for this: - C - Center horizontal point of the child control
- P - Proportionally (like a percentage) relocated
- C - Based on the Center of the parent control
- F - The Far vertical edge of the child control
- F - Using a Fixed (number of pixels) relationship to the parent control's edge
- F - Using the Far edge of the parent control
Regardless of the above, you still must set the location of the control in pixels to be positioned in the center of the parent control. (Still based on the upper-left corner of the child control) You cannot give locations as a wildcard.
Last edited by EQAditu : 01-18-2010 at 05:45 PM.
|
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-18-2010, 06:03 PM
|
gm10-1
|
|
Join Date: Feb 2006
Posts: 6,479
|
|
Quote:
Originally Posted by EQAditu
Though I cannot say that I understand what "right,bottom" would mean because that doesn't follow the format the UI builder documentation specifies.
|
The UIbuilder doc is outdated and incomplete, right, left and center as well as top, center, bottom are valid keywords for PackLocation.
|
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-18-2010, 08:28 PM
|
![EQAditu's Avatar](image.php?s=c7593d4545cff0da91d4432063400585&u=30990&dateline=1178591966) |
A Griffon
|
|
Join Date: Mar 2005
Server: Permafrost
Posts: 256
|
|
Well, I'll just then say that I don't like the new available keywords because it doesn't give you the ability to specify all of the options. So my advice stands.
What would "right,bottom" even mean? Is it "FFF,FFF" or is it "NFF,NFF"? If the PackSize is "F,F", it doesn't matter. But if you use any combination of A or P instead of F, it will change the behavior.
I simply don't like shortcut keywords(that aren't even shorter) that create ambiguity. But whatever... to some people that don't want to learn what the shorthand letters mean, I guess learning the full words may be okay.
Last edited by EQAditu : 01-18-2010 at 08:31 PM.
|
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-19-2010, 06:07 AM
|
gm10-1
|
|
Join Date: Feb 2006
Posts: 6,479
|
|
right, bottom is FFF,FFF if I remember correctly. I have used both in my code in the past, even in combination (e.g. cfc,bottom is valid).
Having options for convenience is never bad. While I can code assembler I prefer to use high level programming languages for the same reason. ![Smile](/images/style_mmoi_eq2i/smilies/smile.gif)
|
![Unread](/images/style_mmoi_eq2i/statusicon/post_new.gif)
01-19-2010, 08:46 AM
|
![EQAditu's Avatar](image.php?s=c7593d4545cff0da91d4432063400585&u=30990&dateline=1178591966) |
A Griffon
|
|
Join Date: Mar 2005
Server: Permafrost
Posts: 256
|
|
Quote:
Originally Posted by gm9
{...}
While I can code assembler I prefer to use high level programming languages for the same reason. ![Smile](/images/style_mmoi_eq2i/smilies/smile.gif)
|
Sure, but if you want to use such broad analogies, I can do that too.
I used to like foreach in programming because it allowed me to skip specifying the conditions of exiting and incrementing a number in a for loop. Then I found out that in most of the cases that I used it, it caused my program to be slower. So I stopped using it completely because it would never be faster and usually slower if I was careful as to how I coded the rest of the loop. So to sum up this analogy, easier is not always better.
PS, I wonder what the OP thinks of how this conversation is turning out.
PPS, I wish that .NET Forms programming actually had this level of detail. Specifically proportional resizing and relocation. Using table containers are just cumbersome.
Last edited by EQAditu : 01-19-2010 at 08:50 AM.
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 09:01 PM.
|
![](/images/style_mmoi_eq2i/layout/clear.gif) |