layout

Concerns - Table layout, iFrames, code deprecation

I am working with a simple table-based layout that uses iFrames as depicted in the example below. This code is rendering well in all modern browsers. The iFrames are usually filled with long tables of data, but there is no odd behavior or clipping. My concern is that it LOOKS like a really bad hack to me. Table-based layout evils a...

Silverlight cutting off text/ wrapping it and not displaying correctly

Please help me understand the issue behind this and it's fix, I'm having agood deal of trouble getting the behaviour I want with text display. With certain lengths of strings the TextBlock wraps around, but does not update the control to show the second line, in effect making part of the text dissappear. This works fine in XamlPad, but...

Iframe problem with IE6 & IE7

Hi all, I'm experiencing difficulties getting my iframe to display correctly in IE6 & IE7. www.e-g-t.nl I think IE has the height of the iframe stretched to far beyond the 400px height I set it to be, and the content is vertically centered. I'm not an expert at css or html for that matter and don't seem to get it right. In IE8 though, ...

What is the best Rails caching option for largely static pages with a dynamic header

I have a set of largely static pages which I'd be happy to page cache for relatively long periods apart from the fact that their layout includes a much more dynamic header. The most promising idea so far seems to be using action caching without layout :- class SomethingController < ApplicationController caches_action :index, :layout...

Why does my CSS (apparantly) force a scrollbar to appear regardless of content size?

I apologize for the long paste of code here, but this has been bugging me for a good few hours now. I'm working on porting my entire site over into a new template, and I'm trying to make the various areas and things more size-aware so I can contain most of them in resizeable dockable windows and things, a very neat concept that's working...

How do I tell if an HTML element has gone off the bottom of a page?

I have a system that takes dynamic data, puts it in HTML for layout and then converts that to PDF. However the problem I am having is that if an element becomes too big for the remaining page space or pushes something else off the bottom how can I detect this and move the element myself to the right position on the next page? (Currently ...

Do you put conditional code on a new line or only sometimes?

I generally will always write conditional code along the lines of if (number==1) name="a"; if (number==2) name="b"; no matter how short, although I find a fair chunk of people writing if (number==1) name ="a"; if (number==2) name ="b"... To me this seems inconsistent, and actually makes the code look messier. What is the...

Cocoa: Learn currently selected keyboard layout / input language

Hello! How do I learn currently selected keyboard layout / input language? I was playing with NSInputManager but wasn’t able to achieve anything. [NSInputManager currentInputManager] returns (null) (as reported with %@) and thus [[NSInputManager currentInputManager] localizedInputManagerName] It would be the best for me to just g...

CSS fluid 'column'

Whats the best way to get this layout in CSS? imagine that I have three divs, two divs inside another.. of the two inner divs, the first one has a specific width set, and the second div is expected to take up the remaining space. Generally I'd end up setting a specific width on the second column, and manage updating this in the end that...

Need to solve CSS DIV Default width problem: Looks good in IE. Not Firefox.

I've set up an example of what I'm running into here: http://studiozion.com/cssproblem/fix_it.htm. Relevant code blocks... <style type="text/css"> body { background: transparent url(Grade300_Color1.png) repeat-x } .RowMaker { overflow: auto; } .ColumnMaker { float: left; } .ColumnMaker2 { float: right; } .PadTop { ...

Arranging dynamically created controls on a web form

Hi. I am a newbie if it comes to web site development. I would like to create a web form that would contain controls defined in an XML file. This means that I am going to read the XML file within the Page_Load function and dynamically create and name all controls as defined in the file. This seams to be very easy. I have, however, anot...

Fixing flowlayout in Java

Hi I have created a GUI for my program in Java, and I have used flowlayout (didnt have much luck with borderlayout), but with flowlayout if the user resizes the program, everything goes out of alignment, so i'm wondering is there anyway to stop the frame of the program from being resized? if so how? Thank You ...

How to keep relative position of WPF elements on background image

Hi folks, I am new to WPF, so the answer to the following question might be obvious, however it isn't to me. I need to display an image where users can set markers on (As an example: You might want to mark a person's face on a photograph with a rectangle), however the markers need to keep their relative position when scaling the image. ...

What would be the best way to make this layout (css or tables) ?

Hi, I am developping an application where there are subscriptions available. I wanted to know what would be the best way to structure data like the following schema (using tables or css). (Sorry, I am at work and cold not post the picture of what I want on a free image hosting service.) |¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯...

ImageView trouble

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:src="@drawable/wallpaper"...

How to display content that differs across controllers and methods in application layout?

I'm trying to display a javascript feedback widget in my default application.rhtml in a rails app. It will only appear on a subset of pages, distributed across different controllers. Trying to figure out the best way to do this. One thought was to do something like this: <%= render :partial => "layouts/feedback_tab" if @show_feedb...

flex sprite scroll bars

Please find the code below.When you run the example(attached file) and click on tools(top left)-> zoom in(click 2 times), you will see that the yellow color is scaled and goes beneath the blue color. What I was expecting is the yellow color will get scroll bars and it will not cross the boundaries. I have tried for quite some time but c...

Truncating long strings with CSS: feasible yet?

Is there any good way of truncating text with plain HTML and CSS, so that dynamic content can fit in a fixed-width-and-height layout? I've been truncating server-side by logical width (i.e. a blindly-guessed number of characters), but since a 'w' is wider than an 'i' this tends to be suboptimal, and also requires me to re-guess (and kee...

How do I keep multiple DIVs the same height using jQuery?

I've got a few DIV tags with different amounts of text content. HTML: <div id="boxes"> <div id="boxone"> <p>...</p> </div> <div id="boxtwo"> <p>...</p> </div> <div id="boxthree"> <p>...</p> </div> <div id="boxfour"> <p>...</p> </div> </div> They're in a two-by-two layout...

How do I remove the height style from a DIV using jQuery?

By default, a DIV's height is determined by its contents. But, I override that and explicitly set a height with jQuery: $('div#someDiv').height(someNumberOfPixels); How can I reverse that? I want to remove the height style and to make it go back to it's automatic/natural height? ...