How to set a fixed width for a box

Hi there,
Struggling here.... must admit. 
I need a solution whereby I can set a fixed width for a box that is grouping two buttons.  I suppose generally, I want to know how to set a fixed width for anything element.
See the picture below.  I want the two buttons to stay the same distance apart, and I want the grouped buttons to stay the same distance from the right edge of the window, even as a user resizes the window.
This is what happens when you reduce the size of the window .....
I would like to stop this from happening.
I can't figure out how accomplish keeping the parent div a fixed width, and a fixed position from the right side of the window, so the buttons won't overlap.
Perhaps I'm doing the whole thing wrong. 
I mean, is there a way to accomplish this without grouping the buttons?  That is, make the buttons fixed width, fixed distance apart from each other, and fixed distance from the right side of the window, even as the user resizes the page?
I am trying to accomplish this using the Min/Max width settings, but given that there are so many different units to choose from, and the fact that when I place a button or box on the screen, it seems to be creating that button or box with a percentage-based width, I don't know how many pixels to set it to.... sigh....
Many thanks in advance for your help.
Sam

Okay after much futzing I figured out at least part of the solution I need, but if someone knows of a more efficent way to do this please let me know. 
I set a fixed minimum width in pixels for both of the buttons at 156px.
I then made the left button float left and the right button float right.
I then made the parent div for the buttons float right.
That made the buttons stay the same size.
The only thing I need to figure out how to do now is make the parent div stay a consistent distance in pixels from the right.  I tried setting a right margin but that didn't work.  As you size the window down, the div gets closer to the edge, until it passes it.  

Similar Messages

  • How to set displayed column width for a search help

    I have created an elementary search help for a custom field with a value table behind it.
    The search help functions correctly, but when displayed the column widths are all 10 characters. The user has to adjust the column to view the descriptive text.
    Can anyone tell me how to set default column widths for the help?

    Please  open you Elementary search  help  and see the Column  width   behind the Fields of your ...there  increase the width of the fields
    "Activate it  and refresh
    reward  points if it is usefull .....
    Girish

  • How to set initial column widths for a table

    What I'd like to do is to control the initial column widths for a table.
    I'm building the table by using a class which extends AbstractTableModel. This class takes care of setting the headers and reading the data for the table.
    If I do the following:
    VarTableModel vtm = new VarTableModel(vi);
    JTable jt = new JTable(vtm);
    JScrollPane jsp = new JScrollPane(jt);
    frame.getContentPane().add(jsp);
    frame.setVisible(true);
    I will see a table in my window. The widths of the columns are equal and are a function of the horizontal dimension of the window.
    I have tried to set the width of a column by doing the following:
    TableColumn aColumn;
    aColumn = jt.getColumn(vtm.getColumnName(0));
    aColumn.setWidth(40);
    But this has no effect on what gets displayed. I can force the widths that I want by using 'setMaxWidth' but this has the unfortunate side effect of not allowing the user to make the column wider if they want.
    What I'd like is a way to specify the widths of the columns when initially displayed and then let the user adjust to their liking.
    I'm sure that there is a way to do this, but I don't seem to understand where to intervene in the process to produce the effect that I want.
    Any help or suggestions will be greatly appreciated!

    Table.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
    add this line and try ur codeThanks for the suggestion! Unfortunately, it doesn't seem to do the trick. Here is an abbreviated segment of my code:
    vtm = new VarTableModel(vi);
    JTable jt = new JTable(vtm);
    // we want a horizontal scrollbar, so turn resizing off
    // and we want to control column widths
    jt.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
    aColumn = jt.getColumn(vtm.getColumnName(0));
    aColumn.setWidth(40);
    . // same kind of thing for each column
    aColumn = jt.getColumn(vtm.getColumnName(4));
    aColumn.setWidth(400);
    JScrollPane jsp = new JScrollPane(jt);
    frame.getContentPane().add(jsp);
    frame.setVisible(true);
    If I do the above, the table gets displayed with each of the five columns the exact same width. So, the sizing of the columns is happening somewhere else despite turning auto resizing off.
    Where is that occurring and how can I intervene so that I can control the widths of the columns on initial display and still allow the user to adjust the widths if they so choose?

  • How to make a fix width for a select list

    APEX 4
    good day everyone I have an apex_item selectlist. My question is How do I make a fix width on it?

    http://download.oracle.com/docs/cd/E17556_01/doc/apirefs.40/e15519/apex_item.htm#CHDHJJAB
    APEX_ITEM.SELECT_LIST(
        p_idx           IN   NUMBER,
        p_value         IN   VARCHAR2 DEFAULT NULL,
        p_list_values   IN   VARCHAR2 DEFAULT NULL,
        p_attributes    IN   VARCHAR2 DEFAULT NULL,
        p_show_null     IN   VARCHAR2 DEFAULT 'NO',
        p_null_value    IN   VARCHAR2 DEFAULT '%NULL%',
        p_null_text     IN   VARCHAR2 DEFAULT '%',
        p_item_id       IN   VARCHAR2 DEFAULT NULL,
        p_item_label    IN   VARCHAR2 DEFAULT NULL,
        p_show_extra    IN   VARCHAR2 DEFAULT 'YES')
        RETURN VARCHAR2;Specify
    p_attributes => 'style="width: 200px;"'for a width of 200px.
    Ta,
    Trent

  • How to set dynamic column width for analysis item

    Dear Experts,
    I have a query view which is added in the web template as an analysis item. The web item properties on width is not working - I tried entering a value in the width but when I execute the template, the query view's width still stays the same.
    Module com.sap.ip.bi.rig.ColumnWidth don't seem correct because I don't want the column width to be static. As my number of columns may change, I wanted the overall width of my query view to stay the same.
    Appreciate any ideas which can solve this issue
    Thanks and Regards,
    huimin
    BW newbie

    Hi Huimin,
    I don't think it is possible to fix the width of the Analysis webitem since it dynamically adjusts its width based on the text maxlength within its cells. Unless you use com.sap.ip.bi.rig.ColumnWidth where the cols are static, you cannot achieve this.
    Even if you do override the css settings using a cell padding or something, the portal settings would override the same. How about using a Report webitem to insert tables/charts & check if the width can be adjusted here - just a thought.
    --Priya

  • How to set a fixed size for the browser window on startup?

    so the browser window has the same size and location on the desktop every time i open a new window???

    In a 2D coordinate system the horizontal values are represented by some letter, usually x. In the same coordinate system the vertical values are classically represented by y.
    Note: In your code, if you wish, you can replace x and y with anything you desire--p and q or perhaps jeff and alice or any variable name you wish, but for simplicity, and usually ease of understanding because almost everyone has had 100's of math problems drilled into their head with (x, y), x and y are used as convention.
    In Java the screen coordinates run from 0 to the width-1 for x and 0 to height-1 for y of the component you are using to display.
    So logically when you have a value of x or y that goes beyond the addressable bounds of your display, then you have to make some type of adjustment--when your value dips below 0, you reset it to 0, when your value goes above what ever width-1 or height-1 then you have to set that value to width-1 or height-1.
    This all assumes that when you hit the wall, floor, or ceiling you stick there until you change directions--if you wish to wrap then you set your value to the opposite bound--so if you go below 0, you would then pop out back in on the right side--your appropriate x would be set to width-1 instead of 0 and in the case of y going below 0 your y would be set to height-1. This is also to say that when you descend below your minimum, then you would pop back out on the opposite side you went out on--so x greater then width-1 would get set to 0 and y greater than height-1 would get set to 0.
    That is not even a start on if you want to include elastic collisions, angle of impact, any type of deceleration force, or anything else.
    In any case... I would recommend that you add more math to your studies, I've never met an engineer or computer science grad that said: "Wow, I really regret taking all that math in college (or HS), I never use it."

  • How to set a minimum width and height for a stage or scene?

    Hello,
    Does anyone how to set a minimum width and height for a stage or scene?
    I tried listening for width/height property value changes and then adjust the width/height if necessary, but that causes unpleasant flickering of the window.
    In JavaFX 2.1 beta SDK for Mac OS, the Stage class has setMinWidth() and setMinHeight() functions which work very well.
    I'm wondering what's the equivalent way to do that when using the FX SDK for Windows.
    Any help is appreciated!
    Thanks.

    I was wondering how to enforce a minimum stage size with JavaFX 2.0.3.The same flickering way you are currently doing it. See: http://javafx-jira.kenai.com/browse/RT-15200 "Need a way to set the minimum size of a window"

  • How to set the fix size jframe window

    when I run the jframe ,the jframe window size is very small
    1)how to set the fix size jframe window??
    2)how to set the jframe cannot change the window size??
    thx~~

    1. You can set the size by calling JFrame's method setSize. There are two versions of this method: (1) setSize(int width, int height) and (2) setSize(Dimension d). Note, that when you use this method to set the frame size, you don't have to call JFrame's pack method.
    2. JFrame has a method called setResizable(boolean resizable) which you can call with the argument false.
    Without any ill intent, these questions are regarding something that is very easily answered by looking at the documentation for the JFrame class. I suggest to anyone working with swing to at least look briefly through the base classes they're extending before giving up. In my experience it is always more gratifying to figure things out on my own than asking someone. But please don't take this the wrong way, I respect people who seek out help in order to further their knowledge, instead of just giving up.

  • How to set-up a Timestamp for BI Delta Load in 0CLM_INVOICE datasrc at R/3?

    Hi Experts,
    Kindly let me know How to set-up a Timestamp for BI delta load at R/3 for the Data source 0CLM_INVOICE ?
    Since the Timestamp for Upload of BI Delta is " . . : : ", we are not getting any delta value to BW.
    I would like to know in where we need to maintain the DATE & TIME to fix the above problem.
    Thanks.
    Regards,
    Jayaprakash J

    Dear Jayprakash,
    Chech the below links, it may help you in your case :
    Re: 0FI_AA_11 Delta load failure
    http://wiki.sdn.sap.com/wiki/display/BI/GeneralErrorIn+BI
    Actaully you need not have to maintain the timestamp. Just try to replicate your datasource and the try to load the delta again.
    Hopefully it will work.
    Regards,
    Rahul
    Edited by: Rahul on Dec 10, 2010 10:23 AM

  • How to create a fixed-width column within an APEX 4 interactive report?

    This thread is a follow-up to {message:id=9191195}. Thanks fac586.
    Partial success: The following code provided by fac586 limits the column width of the Apex 4 interactive report column as long as the column data contains whitespace within a Firefox 3.6 browser:
    <pre class="jive-pre">
    <style type="text/css">
    th#T_DESCRIPTION {
    width: 300px;
    td[headers="T_DESCRIPTION"] {
    width: 300px;
    word-wrap: break-word;
    </style>
    </pre>
    Notes:
    1. The code above is put into the HTML header section for the page.
    2. T_DESCRIPTION is defined as VARCHAR2(2000).
    3. The code above works within the Firefox 3.6.12 browser but does not work within the Internet Explorer 7.0.5730.13 browser.
    I tried adding "float: left;":
    <pre class="jive-pre">
    <style type="text/css">
    th#T_DESCRIPTION {
    width: 300px;
    td[headers="T_DESCRIPTION"] {
    width: 300px;
    word-wrap: break-word;
    <font color="red"> float: left;</font>
    </style>
    </pre>
    Notes:
    1. "float: left;" does not require whitespace and successfully splits the column between characters in lieu of whitespace.
    2. "float: left;" shrinks the cell height and allows the page background to show through... couldn't determine how to fix this.
    3. The code above works within the Firefox 3.6.12 browser but does not work within the Internet Explorer 7.0.5730.13 browser.
    I've done some more research, but I still haven't discovered how to create a fixed-width column within an APEX 4 interactive report that displays properly within an Internet Explorer 7 browser.
    Any ideas and help will be appreciated.

    Thanks for your help with this!
    <pre class="jive-pre">
    what theme are you using?
    </pre>
    A customized version of theme 15.
    <pre class="jive-pre">
    Floating a table cell makes no sense (to me anyway).
    </pre>
    You are correct. I was just trying a different approach ... trying to think out of the box.
    <pre class="jive-pre">
    Think you'll need to create an example on apex.oracle.com with sample data
    if there are any further problems.
    </pre>
    Great suggestion! The code your provided works in the Firefox 3.6.12 browser, but still doesn't work within my Internet Explorer 7.0.5730.13 browser.
    UPDATE:
    I have recreated the problem at apex.oracle.com, you can use the following information to check it out:
    URL: http://apex.oracle.com/pls/apex/f?p=43543:100::::::
    Workspace: IR_FIXED_WIDTH_COLS
    Username: GUEST
    Password: Thx4help
    Application: 43543 - CM_RANDY_SD
    Note: Table name is TEST_DATA
    The following code provided by fac586 works in both Firefox 3.6 and IE7 using default theme "21. Scarlet" at apex.oracle.com; however, it doesn't work when I use a copy of our customized theme "101. Light Blue":
    <pre class="jive-pre">
    <style type="text/css">
    .apexir_WORKSHEET_DATA {
    th#T_DESCRIPTION {
    width: 300px;
    max-width: 300px;
    td[headers="T_DESCRIPTION"] {
    max-width: 300px;
    word-wrap: break-word;
    </style>
    <!--[if lt IE 8]>
    <style type="text/css">
    /* IE is broken */
    th#T_DESCRIPTION,
    td[headers="T_DESCRIPTION"] {
    width: 300px;
    </style>
    <![endif]-->
    </pre>
    Any idea what in the theme could be causing the fixed width column to be ignored in IE 7?
    Edited by: CM Randy SD on Dec 7, 2010 11:22 AM

  • How to determine the fixed width I can use to generate html columns in java

    I have a jsp where I dynamically generate menus for a web page.
    Table's cells are generated with different width, making the menus look differently.
    When clicking on menus, cells changing sizes.
    What is the best way to implement that, so I have a fixed width for every column?
    Thank you

    That's what I do.
    The code determines the width of the column now.
    The only drawback is that I manually assign values to the width depending on the menu item length.
    Is there any way how to do it dynamically, by determining how many px width will be by having the menu item lenght?
    <TABLE cellspacing=0 cellpadding=0 border=0 width="100%">
                   <!--<TR>-->
                        <!--<td width="251"><img src="images/Menu1L.gif" width="8" height="25"></td>-->
                   <%
                        int gs = menu.getSelectedGroupNum();
                        MenuGroup menuGroup = menu.getMenuGroup(gs);
                        int is = menu.getSelectedItemNum();
                        int maxScr = 10; //10 screens buttons per line
                        int totScr = menuGroup.getSize(); //total number of screens for the selected menu
                        int rowsNum = 0;
                        rowsNum = (int)Math.ceil((double)totScr/maxScr);
                        System.out.println("Num of scr per line: " + maxScr +
                                                 " Num of scr/menu: " + totScr +
                                                 " Num of rows: " + rowsNum);
                   for(int     screenRow = 0; screenRow < rowsNum; screenRow ++){
                        //for (int item = 0; item < menuGroup.getSize(); item++)%>
                   <tr><td>
                        <table border="0" cellspacing="0" cellpadding="0" height="20">
                         <tr>
                           <td width="251"><img src="images/Menu1L.gif" width="8" height="25">
                        <%
                        for(int item = screenRow*maxScr; item < (screenRow + 1)*maxScr && item < totScr; item ++)
                             MenuItem menuItem = menuGroup.getMenuItem(item);
                             String title = menuItem.getDisplay();
                             String link = null;
                             String cssClass = null;
                             System.out.println(title + ":" + title.length());
                             if(!menu.isDisabled())
                                  link = "<A href=\"Menu.do?top=" + gs + "&side=" + item + "\">";
                             %>
                             <%
                             else{
                                  link = "";
                                  title = "<i>" + title + "</i>";
                             MenuItem subMenuItem = null;
                             boolean isSubMenu = menuItem.containsSubMenuItem();
                             String subText = null;
                             //determine the width of the column
                             int width = 0;
                             if(title.length() > 5 && title.length()<20)
                                  width = 158;
                             if(title.length() > 20)
                                  width = 193;
                             if(title.length() <=5)
                                  width = 60;
                             if (is == item){
                                  //link = "<A href=\"Menu.do?top=" + gs + "&side=" + item + "\">";
                                  cssClass = "ScreenItemSel A";
                             else
                                  cssClass = "ScreenItem";
                             %>
                             <TD align = "center" nowrap class = "<%= cssClass%>"  background ="images/Menu1F.gif" width="<%=width%>"> <%=link%><%=title%></TD>
                             <TD class="Screen" nowrap><img src="images/Menu1Sep.gif" height=25 width=16></TD>
                        <%                         
                        }%>
                                  <TD width="100%" valign=top align=right class="ScreenName" background="images/Menu1F.gif"><%--<%=mode%>--%></TD>
                                  <TD><IMG src="images/Menu1R.gif" width="8" height="25"></TD>
                             </td>
                        </tr>
                        </table>
                   </td>
                   </tr>
                   <%}
                   %>
                   <!--</TR>-->
    </TABLE>

  • How to set a date range for date field ?

    Dear Experts,
    Scenario:
    I have a query in validating the date field in my BSP application. My application is for maintain infotype 0023 Other/Previous Employers online by employees in the company.
    As per our design we are maintaining the all employment details of the employee both ( with in the current company / previous employment outside the company) in the same infotype.
    Every employee will have a hiring date within the SAP HR system. We consider this date as the cutoff date between current and previous employment in our application. When the employee updating the details wia BSP page I need to check the following.
    Record inside current company: Validation that, the user should only able to enter BEGIN DATE (BEGDA)  greater than or equal HIRING DATE and END DATE(ENDDA) should be greater than FROM  DATE (BEGDA).
    Record outside current Company: Validation that, the user should only able to enter BEGIN DATE (BEGDA)  less than or equal HIRING DATE and END DATE (ENDDA) should be greater than FROM  DATE (BEGDA) and less than HIRING DATE.
    Technical Requirement:
    How to set a date range for date field, i.e. how we can limit the date range in a HTMLB date field? Can this it be achieved via standard functionality of HTMLB?
    Following is the code to describe date field in my application.
        <htmlb:inputField id= "ENDDA_NEW_IN"
                          type= "date"
                    doValidate= "TRUE"
                      showHelp= "TRUE"
                      disabled= "FALSE"
                         width= "183"
                         style= "cssTextAreadate"
                         value= "<%='99991231'%>"/>
    Thanks a lot in advance for your assistance and help.
    Cibinu2026
    Edited by: cibin kuruvilla on Nov 12, 2008 11:13 AM

    Hi,
    This functionality is known to be very important and is a key part of the next major release of the JRC planned for the first half of 2008.
    Regards,
    <p>Blair Wheadon</p>
    <p>Product Manager, Crystal Reports</p>

  • Set default width for text box in Adobe Acrobat X

    Hello!
    I am using the textbox tool to add comments to a document. (not the Typewriter, but the Textbox, since that has more flexibility for formatting the text).
    I know how to set the default proprties for text size, color, background color, etc.
    Cannot figure out however to to set the default width. Every time I try to add a new textbox, it defaults to about 1 or 2 inches wide, so the text wraps around and around, and then I have to resize the box when I am done.
    Is there a way to change the default width?
    Thanks!

    Hi, Amonra
    I drew a box I like, and select, and then, Ctrl+C, and then Ctrl+V.
    And move the pasted box where to need, and resize the length. At least I get same width boxes.
    I don't know how to default it.
    I hope it may help you.

  • Issue with having to declare fixed width for my top level floated LI in horizontal menu

    Hi and thanks for taking a look at my problem:
    I am having trouble getting my sub menus to display correctly in IE.
    Originally i didn't declare a fixed width for my top level li and it displayed perfectly in all browsers except IE.
    If i don't declare a fixed width for my floated floated elements, IE treates the top level li as the same width as the ul they contain (which I don't want). So I declared a width for the ul.MenuBarHorizontal li to be 80px, which is close to the minimum width that i want to use for the top level list items. However, in actual fact, the top level list items all have individually declared widths in the classes they are assigned.
    How can i re-write the html or CSS so that the browser, mainly IE, reads the correct widths for the top level ist li??
    Here is a link to the page with the problem
    Thanks in advance if anyone can help me out.

    Hi Beth,
    thanks so much for your repsonse.
    I will take your notes and advice and see if i can apply it to the actual page i was referring to. It seems you were now looking at a completely different page with a different (albeit spry) horizontal menu.
    Again, i truly appreciate your time and advice.
    Thanks!

  • SRM 4.0- How to set the default values for product type (01) only for SC

    The radio button “Service” should not be visible.
    Also for search help (e.g. search for internal products) where a search should only be possible for product type 01 (goods). The system should not display the product type and internally always search for goods only.
    How to set the default values for product type (01) only for SC
    We needs to use Search help BBPH_PRODUCT which having parameter PRODUCT_TYPE
    Here we can set defalut value 01 but it is not correct one since same search help is using several places.
    We need to limit the search help results only for SC.
    Kindly help out me ASAP.

    The easiest way to set defautl values is to edit the batch class.
    Goto the characteiristic and go to update values.
    In here you probably have something like 0 - 100 as a spec range.
    On the next line enter the default value within this range.  At the end of the line, click in the box in the column labelled "D".  This indicates the defautl value for the characteristic.
    If you need to you can do this in the material classification view as well.
    Just to be clear, these values will only show up in the batch record.  You can not have defautl values in resutls recording screens.
    FF

Maybe you are looking for

  • How to handle paragraph styles in imported text with no tagged paragraph styles

    Hi Im currently trying to import a file (word file / excel I have both formats) into an indesign book and formatting the text automatically! My question is: How is it possible to reflow text into frames and when changing frame it changes paragraph? O

  • After alert clear with script, how to get a new notification email

    I have used em_severity.delete_current_severity to clear my history alert message, it works very well. My question is after clearing the alert list, how to let oracle send another new email to me? For example, I cleared on tablespace 90% full alert,

  • Powerbook 100

    Hi Like Gail I have two powerbook 100's both are doing the same thing. They both will start to boot up . I can hear the hard drive spin up , it then make a series of clicks pauses then start to click again . After a couple time it stops and you get t

  • Buildclient requires mfrts32.lib, COBOL, Fujitsu Tuxedo 8

    When trying to compile under NT 5 (Windows 2000) with Tuxedo 8 and using the Fujitsu COBOL compiler, buildclient & buildserver are trying to link in the library mfrts32.lib. This appears to be the runtime library for MicroFocus Cobol and is NOT part

  • Adding audio to a sequence.

    Forum, I asked for advice about adding voice over to a sequence May 19 2009 and received useful advice. I have only been able to use the advice today. The problem seems to be the volume of the sound I am recording . I am using a Sony microphone and t