Questions tagged [stretch]

Stretching images in code.

516 questions
16
votes
7 answers

Html/Css - How to get an image to stretch 100% width of a container then display another image over it?

I am struggling with getting the layout of the header i have in mind together. Here is the html so far:
13
votes
5 answers

Phonegap splash screen for android: not stretched or 9patch

I have a fake splash screen that pops up when my phonegap app is launched: super.setIntegerProperty("splashscreen", R.drawable.splash); super.loadUrl("file:///android_asset/www/index.html", 500); I currently have 3 different splash.png files: hdpi,…
user1198646
  • 131
  • 1
  • 2
  • 6
13
votes
3 answers

WPF: Expand TextBox by available width but NOT by its content?

I need a good solution for making a TextBox in a grid to expand to its available space but not expand according to how long the text in it happen to be. Most solutions I have found is to make a dummy-border and bind to its ActualWidth but its a to…
Andreas Zita
  • 7,232
  • 6
  • 54
  • 115
13
votes
3 answers

Scale an image to maximally fit available space and center it

I am building a single page application. In one of the views I want to show an image which must take as much available space as possible: most important: it must keep the aspect ratio it must not be cropped it must be stretched horizontally and/or…
blueFast
  • 41,341
  • 63
  • 198
  • 344
11
votes
1 answer

GridView and excess space padding

I have a problem with grid view layout on Android. I can't find solution to eliminate extra space in grid view. I tried a lot of things (numColumns, columnWidth, stretchMode, gravity) and advices (from StackOverflow), but nothing works correctly. I…
petrnohejl
  • 7,581
  • 3
  • 51
  • 63
11
votes
2 answers

how to stretch listviewitem in listview

developers. I try to stretch listview item in horizontal orientation. I do reset ItemContainerStyle ,and the horizentalalignment is strech. Here is all code in the MainPage.xaml.
maoleigepu
  • 153
  • 2
  • 9
10
votes
3 answers

Find element stretching a web page?

I'm doing some work for http://digitaleditor.com/ and I've run into something a tad confusing. The web page has a horizontal scroll bar at the bottom, but I've been unable to figure out why. Using Google Chrome's developer's tools I've found that…
stevendesu
  • 15,753
  • 22
  • 105
  • 182
10
votes
6 answers

Make HTML input stretch to fill space in container

There is a
element which is resized depending on page width. It contains and elements. How can I make the align by the right side of the
9
votes
5 answers

Stretching a WPF Canvas Horizontally

How do I make a Canvas stretch fully horizontally with variable width? This is the parent Canvas, so it has no parents, only children. XAML Source: it displays in blend http://resopollution.com/xaml.txt
resopollution
  • 19,600
  • 10
  • 40
  • 49
9
votes
4 answers

How do I make an image stretch to fill in this WPF / XAML application?

When my program displays an image which is smaller than the Image GUI object defined in XAML, it does not get stretched to fit as I would like it to. For example a 256x256 image only occupies the upper left quadrant of my 512x512 Image GUI object.…
myjy012003 a
  • 91
  • 1
  • 1
  • 2
9
votes
1 answer

CGImage gets stretched in CALayer

I have an NSMutableArray of CGImage objects. All the images have different dimensions ( 80x20 px, 200x200 px, 10x10 px, etc...) I'm trying to animate these in CALayer which has 256x256 pixels size. The animation works, but my CGImages get stretched…
PrimeSeventyThree
  • 940
  • 2
  • 9
  • 24
9
votes
2 answers

iPhone stretchableImageWithLeftCapWidth only makes "D"s

UIImage *aImage = [[UIImage imageNamed:@"Gray_Button.png"] stretchableImageWithLeftCapWidth:25 topCapHeight:0]; Trying to make a "glass pill button". What does "stretch" do if the image is bigger... and the button I'm trying to use it on... is…
Susanna
  • 771
  • 3
  • 10
  • 17
9
votes
2 answers

CSS, Stretching vertically div until it reach the height of its parent

Wrapped in a pageWrapper container, I have 3 divs in a column. First (header) and last (navWrapper) have fixed heights. I need the middle one (contentWrapper) to stretch in height until the parent div pageWrapper reaches the maximum height…
Very Curious
  • 881
  • 3
  • 26
  • 50
8
votes
3 answers

Android ExpandableListView indicator/icon always stretched

I use my own icon image as indicator for ExpandableListView, but the icon seems to be stretched, I tried to put the image file in /drawable and /drawable-hdpi with no luck. If I do not use my own icon, the built-in Android one looks nice, so I…
Heuristic
  • 5,087
  • 9
  • 54
  • 94
8
votes
1 answer

What would be a higher quality alternative to StretchBlt for drawing an HBITMAP?

I don't want to use GDI+'s DrawImage because of speed issues. What other ways are there to draw an image resized with decent quality - at least linear or cubic interpolation?
jnm2
  • 7,960
  • 5
  • 61
  • 99
1
2
3
34 35