Search Results

Search found 10226 results on 410 pages for 'width'.

Page 17/410 | < Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >

  • assigning width to li

    - by badnaam
    I am using jquery ui tabs, which requires the tabs to be <li> elements, by default at least. I only need 2 tabs, but I am not able to size them so that they are both equal and take up 100% of available width of the ul. here is my code. <div id="intro_tabs" class="tabs"> <ul id="intro_nav"> <li> <h3><a href ="#tabs-1" class="null_link"><%= t('home.index.what_is_it') %></a></h3> </li> <li> <h3><a href ="#tabs-2" class="null_link"><%= t('home.index.how_works') %></a></h3> </li> </ul> <div id="tabs-1"> <%= simple_format t 'home.index.what_intro_details' %> </div> <div id="tabs-2"> <div id="intro_accordion"> <h3><a href="#">Users</a></h3> <div> <%= t 'home.index.how_intro_details_user' %> </div> <h3><a href="#">Merchants</a></h3> <div> <%= t 'home.index.how_intro_details_merchant' %> </div> </div> </div> </div> I have tried using css property width:50%, on both li's but it doesn't work. Thanks

    Read the article

  • Block element, horizontal center aligned and minimum width possible

    - by Nazgulled
    Hi, I'm trying to have this block element to be horizontally aligned in the middle but at the same time I would like the width to be the minimum possible for the contents inside. But I don't think it's possible or I'm not able to do it myself... a#button-link { background: url("images/button-link.png") no-repeat scroll center left; margin: 12px auto 0 auto; display: block; width: 125px; height: 32px; line-height: 32px; padding-left: 35px; font-weight: bold; } This is my current code... The idea behind this is that the text for that tag could be slightly bigger or smaller depending on the user language and how much characters the same sentence has for that specific user's language. There's no way I can control but I still would like to have this element horizontally aligned to center. Is this possible with CSS?

    Read the article

  • Loading external SWF with masked content - need width/height

    - by AZSL
    I am loading an external swf using the SWFLoader component. The swf that is being loaded is masked so that only a portion is being shown. However, when it's loaded the actual size of the swf (loader.content.width/loader.content.height) is the complete swf including the masked area. Therefore, the loaded swf does not display properly in the itemrenderer Is there a way to to grab the size of the just the masked area as opposed to getting the size of the entire swf's contents? One item to note that is complicating the issue, is that these are swf files that have already been created and there are many of them. In some instances, the size of the stage matches up with the size of the masked area. In other instances, the stage is larger (or possibly smaller) than the masked area movieclip as well as possibly the actual size of the movieclip (w/o the mask). I am currently loading the external swf in using a Loader. Once loaded, I make a copy (screen shot) of the swf by creating a bmp of the loader.content.This is done as I don't want to have any animations being shown on screen at this moment. I am setting the size of the bmp using using loader.content.width & loader.content.height. I then set the SWFLoader.source to the bitmap.

    Read the article

  • When using Clipboard, Toolkit and Transferable, I get an error objecting to image width and height

    - by Mike King
    When I run the following code it triggers an error message. The error message is shown below the code. What code changes, or changes to the image file, are needed to fix this error? Help will be appreciated. import java.awt.*; import java.awt.datatransfer.*; public class LoadToClipboard { public static void main( String [] args ) { Toolkit tolkit = Toolkit.getDefaultToolkit(); Clipboard clip = tolkit.getSystemClipboard(); clip.setContents( new ImageSelection( tolkit.getImage("StackOverflowLogo.png")) , null ); } } class ImageSelection implements Transferable { private Image image; public ImageSelection(Image image) { this.image = image; } // Returns supported flavors public DataFlavor[] getTransferDataFlavors() { return new DataFlavor[]{DataFlavor.imageFlavor}; } // Returns true if flavor is supported public boolean isDataFlavorSupported(DataFlavor flavor) { return DataFlavor.imageFlavor.equals(flavor); } // Returns image public Object getTransferData(DataFlavor flavor) throws UnsupportedFlavorException { if (!DataFlavor.imageFlavor.equals(flavor)) { throw new UnsupportedFlavorException(flavor); } return image; } } Exception in thread "main" java.lang.IllegalArgumentException: Width (-1) and height (-1) cannot be <= 0 at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:999) at sun.awt.datatransfer.DataTransferer.imageToStandardBytes(DataTransferer.java:1994) at sun.awt.windows.WDataTransferer.imageToPlatformBytes(WDataTransferer.java:267) at sun.awt.datatransfer.DataTransferer.translateTransferable(DataTransferer.java:1123) at sun.awt.windows.WDataTransferer.translateTransferable(WDataTransferer.java:163) at sun.awt.windows.WClipboard.setContentsNative(WClipboard.java:73) at sun.awt.datatransfer.SunClipboard.setContents(SunClipboard.java:93) at automateSignature.LoadToClipboard.main(LoadToClipboard.java:8) I have tried to find a place in the code where width and height can be specified, but have not succeeded. I also examined the properties of the jpg file and the w and h are specified.enter code here

    Read the article

  • C# XAML get new width and height for Canvas

    - by Jack Navarro
    I have searched through many times but have not seen this before. Probably really simple question but can't wrap my head around it. Wrote a VSTO add-in for Excel that draws a Grid dynamically. Then launches a new window and replaces the contents of the Canvas with the generated Grid. The problem is with printing. When I call the print procedure the canvas.height and canvas.width returned is the old value prior to replacing it with the grid. Sample: string="<Grid Name=\"CanvasGrid\" xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\">..Lots of stuff..</Grid>"; // Launch new window and replace the Canvas element WpfUserControl newWindow = new WpfUserControl(); newWindow.Show(); //To test MessageBox.Show(myCanvas.ActualWidth.ToString()); //return 894 Grid testGrid = myCanvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 StringReader stringReader = new StringReader(LssAllcChrt); XmlReader xmlReader = XmlReader.Create(stringReader); Canvas myCanvas = newWindow.FindName("GrphCnvs") as Canvas; myCanvas.Children.Clear(); myCanvas.Children.Add((UIElement)XamlReader.Load(xmlReader)); //To test MessageBox.Show(myCanvas.ActualWidth.ToString()); //return 894 but should be much larger the Grid spans all three of my screens Grid testGrid = myCanvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 but should be much larger the Grid spans all three of my screens //Run code from WpfUserControl.cs after it loads from button click Grid testGrid = canvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 but should be much larger the Grid spans all three of my screens So basically I have no way of telling what my new width and height are Any Ideas

    Read the article

  • Inconsistent table width when hideing/showing a set of columns

    - by Salman A. Kagzi
    I have got a an HTML table of around 40+ columns. To make this table fit in the screen and have the data in a re presentable format we have section in this table. i.e. there are some column that are always visible and the remainder a made visible when s specific radio button (describing a section) is selected. Each radio button is associated to different number of columns. We show/hide a column by setting/removing "display:none" style in all the cell under that column. This all works Just fine. Now the real problem is with the width of the columns in this table. I cant use fixed with with pixel settings. I have tried using the percentage setting by giving 50% to the always visible part and rest 50% is divided between the column in a section. But I am unable to get a fixed behavior i.e. the size of the table columns across IE & FF. Some columns are just right while some are really huge. How can I get the table to give consistent column width across browsers?

    Read the article

  • CSS: how to set the width of form control so they all have the same width?

    - by Alessandro Vernet
    Consider the following example: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <style type="text/css"> div { width: 15em } input, textarea, select { width: 100%; -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box } </style> </head> <body> <form> <div> <input value="Input"> </div> <div> <textarea>Text area</textarea> </div> <div> <select> <option>One</option> <option>Two</option> <option>Three</option> </select> </div> </form> </body> </html> On browser that support the border-box box sizing, this is rendered as I want: On IE 6/7, however, this is rendered as: How can I get the same rendering in IE 6/7 that I get in other browsers, without resorting to setting sizes in pixels?

    Read the article

  • Dynamic width of DIV (offsetWidth issue).

    - by Tom
    Hi all, I face issue with retrieving (via javascript) width of the div which content is changed (just before reading the widht via offsetWidth) in dynamic way (via changing innerHTML or using createTextNode). Here is some sample code: var con = document.getElementById('avContent'); //content div within page var temp = document.createElement('div');<br /> var text1 = document.createTextNode('CCCCC');<br /> temp.appendChild(text1);<br /> con.appendChild(temp);<br /> var length1 = temp.offsetWidth;<br /> var text2 = document.createTextNode('CCCCC33333333vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv');<br /> temp.removeChild(text1);<br /> temp.appendChild(text2);<br /> con.removeChild(temp);<br /> con.appendChild(temp); var length2 = temp.offsetWidth;<br /> The length1 and length2 do have the same width.. (the same result I get while using innerHTML instead of createTextNode). Looks like it's the same issue like described in following discussion: http://www.webdeveloper.com/forum/showthread.php?t=187716 Does anybody have answer (work around)? Thanks much for help in advance.

    Read the article

  • XAML get new width and height for Canvas

    - by Jack Navarro
    I have searched through many times but have not seen this before. Probably really simple question but can't wrap my head around it. Wrote a VSTO add-in for Excel that draws a Grid dynamically. Then launches a new window and replaces the contents of the Canvas with the generated Grid. The problem is with printing. When I call the print procedure the canvas.height and canvas.width returned is the old value prior to replacing it with the grid. Sample: string="<Grid Name=\"CanvasGrid\" xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\">..Lots of stuff..</Grid>"; // Launch new window and replace the Canvas element WpfUserControl newWindow = new WpfUserControl(); newWindow.Show(); //To test MessageBox.Show(myCanvas.ActualWidth.ToString()); //return 894 Grid testGrid = myCanvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 StringReader stringReader = new StringReader(LssAllcChrt); XmlReader xmlReader = XmlReader.Create(stringReader); Canvas myCanvas = newWindow.FindName("GrphCnvs") as Canvas; myCanvas.Children.Clear(); myCanvas.Children.Add((UIElement)XamlReader.Load(xmlReader)); //To test MessageBox.Show(myCanvas.ActualWidth.ToString()); //return 894 but should be much larger the Grid spans all three of my screens Grid testGrid = myCanvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 but should be much larger the Grid spans all three of my screens //Run code from WpfUserControl.cs after it loads from button click Grid testGrid = canvas.FindName("CanvasGrid") as Grid; MessageBox.Show("Grid " + testGrid.ActualWidth.ToString()); //return 234 but should be much larger the Grid spans all three of my screens So basically I have no way of telling what my new width and height are.

    Read the article

  • align li tags with an auto width vs hard coding

    - by Diver Dan
    I am having trouble trying to get a group of li tags to align how I want. I have some basic html <div class="menu"> <ul> <li>Item 1</li> <li>Item 2</li> <li>Item 3</li> </ul> </div>? and some css .menu { border:solid 2px red; width:520px; } ul { border:solid 1px #e5e5e5; height:40px; margin:0 auto; list-style:none; width:500px; } li{ text-align:center; display:inline; margin:10px; } I dont want to hard code li widths for each of the elements but I would like for the li elements to take up all available space with the ul element. What do I need to change to get the result I am looking for? My attempt on jsfiddle

    Read the article

  • Problem with width in percentage in mozilla

    - by lam3r4370
    I have problem with width in percentage in mozilla. Firefox:http://img155.imageshack.us/i/prolemwidthper.png/ Opera:http://img209.imageshack.us/i/logowpopera.png/ Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1"> <meta name="author" content="adminite"> <title>Untitled 2</title> <style> #cont { width:99.8%; height:125px; border:1px solid red; background-color:#1ea1de; margin: 0px 0px 0px 0px; }</style> </head> <body> <div id="cont"> </div> </body> </html>

    Read the article

  • Binding a TextBox's Width to its parent container's ActualWidth

    - by Praetorian
    Hi, I'm loading a Textbox and a Button into a horizontal StackPanel programmatically. The size of the button (which only contains an Image) is fixed, but I can't get the textbox to fill the available width of its parent. This is what the code looks like: StackPanel parent = new StackPanel() { Orientation = Orientation.Horizontal, HorizontalAlignment = HorizontalAlignment.Stretch, VerticalAlignment = VerticalAlignment.Top, }; TextBox textbox = new TextBox() { HorizontalAlignment = HorizontalAlignment.Stretch, VerticalAlignment = VerticalAlignment.Top, //MinWidth = 375, }; Button btn = new Button() { Content = new Image() { MaxHeight = 40, MaxWidth = 40, MinHeight = 40, MinWidth = 40, Margin = new Thickness( 0 ), Source = new BitmapImage( new Uri( "btnimage.png", UriKind.Relative ) ), }, HorizontalAlignment = HorizontalAlignment.Right, BorderBrush = new SolidColorBrush( Colors.Transparent ), Margin = new Thickness( 0 ), }; btn.Click += ( ( s, e ) => OnBtnClicked( s, e, textbox ) ); parent.Children.Add( textbox ); parent.Children.Add( btn ); If I uncomment the MinWidth setting for the textbox it is displayed as I want it to, but I'd like to not have to specify a width explicitly. I tried adding a binding as follows but that doesn't work at all (the textbox just disappears!) Binding widthBinding = new Binding() { Source = parent.ActualWidth, }; passwdBox.SetBinding( TextBox.WidthProperty, widthBinding ); Thanks for your help in advance!

    Read the article

  • jQueryUI dialog width

    - by user35295
    Fiddle Full Screen Example I use jQuery dialog to open tables. Some of them have a large amount of text and they tend to be too long and go way off the screen. How can I make the dialog wider if the table is too long like the first one in the fiddle? I've tried width:'auto' but it seems to just occupy the entire screen. HTML: <button class='label'>Click</button><div class='dialog'><p><table>.....</table></div> <button class='label'>Click</button><div class='dialog'><p><table>.....</table></div> Javascript: $(document).ready(function(){ $('.label').each(function() { var dialogopen = $(this).next(".dialog"); dialogopen.dialog({width:'auto',autoOpen: false,modal: true, open: function(){ jQuery('.ui-widget-overlay').bind('click',function(){ dialogopen.dialog('close'); }) } }); $(this).click(function(){ dialogopen.dialog('open'); return false; } ); }); });

    Read the article

  • Failed to maintain 100% width & height of structure in extjs

    - by ayanonly1
    HI, i am new in extjs. i want to build a page using extjs ____________ |HD__________| | p1      <| p2          | |          |            |--will be a viewport (will resize on window resize without any |          |             | Scroll bar |          |             | |          |             | |          |             | |___|_____| HD-- heading with 100 width p1-- panel 1 which will collapse on west and split = true p2-- panel 2 which will occupy remaining place i build the structure but failed to maintain it 100 % even on window resize bellow is my code EditorUi = Ext.extend(Ext.Viewport, { layout: 'fit', initComponent: function() { this.items = [ { xtype: 'panel', title: 'Heading', autoHeight: true, autoWidth: true, layout: 'hbox', items: [ { xtype: 'panel', title: 'Navigation', collapsible: true, region:'west', width:200, split:'true', margins:'3 0 3 3', cmargins:'3 3 3 3' }, { xtype: 'panel', title: 'container', region:'center', autoHeight: true, autoWidth: true, split:'true', margins:'3 0 3 3', cmargins:'3 3 3 3' } ] } ]; EditorUi.superclass.initComponent.call(this); } }); Ext.onReady(function(){ new EditorUi(); }) thanks in advance

    Read the article

  • Change the width of Master in UISplitViewController

    - by Raj
    Hi, The iPad programming guide says that the splitView's left pane is fixed to 320 points. But 320 pixels for my master view controller is too much. I would like to reduce it and give more space to detail view controller. Is it possible by anyway? Edit: Link to the document which speaks about fixed width - http://developer.apple.com/iphone/library/documentation/General/Conceptual/iPadProgrammingGuide/UserInterface/UserInterface.html#//apple_ref/doc/uid/TP40009370-CH3-SW1 Thanks and Regards, Raj

    Read the article

  • WPF Formatting Issues - Automatically stretching and resizing?

    - by Adam S
    I'm very new to WPF and XAML. I am trying to design a basic data entry form. I have used a stack panel holding four more stack panels to get the layout I want. Perhaps a grid would be better for this, I am not sure. Here is an image of my form in action: http://yfrog.com/7gscreenshot1impp And here is the XAML code that generates it: <Window x:Class="Test1.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Window1" Height="224" Width="536.762"> <StackPanel Height="Auto" Name="stackPanel1" Width="Auto" Orientation="Horizontal"> <StackPanel Height="Auto" Name="stackPanel2" Width="Auto"> <Label Height="Auto" Name="label1" Width="Auto">Patient Name:</Label> <Label Height="Auto" Name="label2" Width="Auto">Physician:</Label> <Label Height="Auto" Name="label3" Width="Auto">Insurance:</Label> <Label Height="Auto" Name="label4" Width="Auto">Therapy Goals:</Label> </StackPanel> <StackPanel Height="Auto" Name="stackPanel3" Width="Auto"> <TextBox Height="Auto" Name="textBox1" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox2" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox3" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox4" Width="Auto" Padding="3" Margin="1" /> </StackPanel> <StackPanel Height="Auto" Name="stackPanel4" Width="Auto"> <Label Height="Auto" Name="label5" Width="Auto">Date:</Label> <Label Height="Auto" Name="label6" Width="Auto">Patient Phone:</Label> <Label Height="Auto" Name="label7" Width="Auto">Facility:</Label> <Label Height="Auto" Name="label8" Width="Auto">Referring Physician:</Label> </StackPanel> <StackPanel Height="Auto" Name="stackPanel5" Width="Auto"> <TextBox Height="Auto" Name="textBox5" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox6" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox7" Width="Auto" Padding="3" Margin="1" /> <TextBox Height="Auto" Name="textBox8" Width="Auto" Padding="3" Margin="1" /> </StackPanel> </StackPanel> </Window> What I really want is for the text boxes to stretch equally to fill up the space horizontally. I would also like for the controls in each vertical stackpanel to 'spread out' evenly as the window is resized vertically. Can any of you experts out there help me out?

    Read the article

  • Relative width for a CSS layout, fixed and fluid mix

    - by Alec Smart
    Hello, I am trying to make a chatroom layout like the following: Now my problem is that I am not sure how to have the container box occupy the whole width and height (with valid doctype) and then make the center div grow if the window grows keeping the rest constant. i am well aware of js/css. so i just need some beginning guideline. i would like to avoid javascript to process and then set heights and widths.

    Read the article

  • change width of UIAlertView in iPad

    - by Krishnan
    Hi Friends, Is there any way to change the frame of the UIAlertView in iPhone or iPad. I tried changing the frame in the following delegate method- (void)willPresentAlertView:(UIAlertView *)alertView; but even then the width of the Alertview remained unchanged. And I think a small Alertview in iPad will not make sense. And I guess there must be a way to achieve it, at least in iPad. Thanks, krishnan.

    Read the article

  • Flex 3 ComboBox skin, limiting text width

    - by Rhys Causey
    I've created a ComboBox skin by extending mx.skins.ProgrammaticSkin. It's working fine, except I can't figure out how to limit the width of the text. Is there a way to control this within the skin? See the attached image for an example of the text going too far. I would like it to stop before the separator line to the left of the down arrow.

    Read the article

  • Calculating Text Width In ActionScript And Flex

    - by Joshua
    I'm trying to calculate how WIDE to make my button, based on the text that it will contain, and when I try to google for how to calcuate something as simplistic as the WIDTH OF SOME TEXT, I go cross-eyed just trying to wade through apparently nonsensical esoteric counter-intuitive voodoo. Can anyone out there help simplify for me how I would write a function like this: public function HowWideWouldThisTextBeIfItWereInThisButton(Text:String,Container:Button):int { ... } Thanks in advance.

    Read the article

< Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >