Issues relating to the resizing of controls, windows, forms or screens.
Questions tagged [resize]
8811 questions
412
votes
32 answers
The simplest way to resize an UIImage?
In my iPhone app, I take a picture with the camera, then I want to resize it to 290*390 pixels. I was using this method to resize the image :
UIImage *newImage = [image _imageScaledToSize:CGSizeMake(290, 390)
…
pimpampoum
- 5,376
- 6
- 20
- 27
411
votes
44 answers
Creating a textarea with auto-resize
There was another thread about this, which I've tried. But there is one problem: the textarea doesn't shrink if you delete the content. I can't find any way to shrink it to the correct size - the clientHeight value comes back as the full size of the…
DisgruntledGoat
- 62,693
- 62
- 192
- 281
386
votes
20 answers
Rerender view on browser resize with React
How can I get React to re-render the view when the browser window is resized?
Background
I have some blocks that I want to layout individually on the page, however I also want them to update when the browser window changes. The very end result will…
digibake
- 3,871
- 3
- 10
- 5
326
votes
17 answers
How to resize an Image C#
As Size, Width and Height are Get() properties of System.Drawing.Image;
How can I resize an Image object at run-time in C#?
Right now, I am just creating a new Image using:
// objImage is the original Image
Bitmap objBitmap = new Bitmap(objImage,…
inutan
- 9,740
- 25
- 74
- 119
311
votes
7 answers
Using jQuery To Get Size of Viewport
How do I use jQuery to determine the size of the browser viewport, and to redetect this if the page is resized? I need to make an IFRAME size into this space (coming in a little on each margin).
For those who don't know, the browser viewport is not…
Volomike
- 21,378
- 19
- 99
- 188
264
votes
24 answers
How to wait for the 'end' of 'resize' event and only then perform an action?
So I currently use something like:
$(window).resize(function(){resizedw();});
But this gets called many times while resizing process goes on. Is it possible to catch an event when it ends?
Rella
- 59,216
- 102
- 341
- 614
240
votes
11 answers
Cross-browser window resize event - JavaScript / jQuery
What is the correct (modern) method for tapping into the window resize event that works in Firefox, WebKit, and Internet Explorer?
And can you turn both scrollbars on/off?
BuddyJoe
- 64,613
- 107
- 281
- 451
219
votes
21 answers
Resize a large bitmap file to scaled output file on Android
I have a large bitmap (say 3888x2592) in a file. Now, I want to resize that bitmap to 800x533 and save it to another file.
I normally would scale the bitmap by calling Bitmap.createBitmap method but it needs a source bitmap as the first argument,…
Manuel
- 7,885
- 10
- 29
- 29
188
votes
5 answers
How to resize an image with OpenCV2.0 and Python2.6
I want to use OpenCV2.0 and Python2.6 to show resized images. I used and adopted this example but unfortunately, this code is for OpenCV2.1 and does not seem to be working on 2.0. Here my code:
import os, glob
import cv
ulpath = "exampleshq/"
for…
Bastian
- 8,555
- 6
- 17
- 8
180
votes
18 answers
How to resize images proportionally / keeping the aspect ratio?
I have images that will be quite big in dimension and I want to shrink them down with jQuery while keeping the proportions constrained, i.e. the same aspect ratio.
Can someone point me to some code, or explain the logic?
kobe
- 14,757
- 15
- 58
- 87
179
votes
14 answers
How to resize a custom view programmatically?
I am coding a custom view, extended from RelativeLayout, and I want to resize it programmatically, How can I do?
the custom view Class is something like:
public ActiveSlideView(Context context, AttributeSet attr){
super(context, attr);
…
herbertD
- 9,587
- 12
- 46
- 74
171
votes
11 answers
How can I scale an entire web page with CSS?
Using Firefox, you can enlarge an entire web page by simply pressing CTRL +. What this does is proportionally enlarge the entire web page (fonts, images, etc).
How can I replicate the same functionality using simply CSS?
Is there something like…
TimH
154
votes
7 answers
WPF: Setting the Width (and Height) as a Percentage Value
Say I want a TextBlock to have its Width equal to it's Parent container's Width (ie, stretch from side to side) or a percentage of it's Parent Container Width, how can I accomplish this in XAML without specifying absolute values?
I want to do this…
Andreas Grech
- 98,643
- 98
- 284
- 354
154
votes
4 answers
Android: How to Programmatically set the size of a Layout
As part of an Android App I am building a button set. The buttons are part of a nested set of LinearLayouts. Using weight I have the set resizing itself automatically based on the size of the containing parent LinearLayout. The idea is, based on the…
codingCat
- 2,148
- 3
- 18
- 25
154
votes
8 answers
Image resizing client-side with JavaScript before upload to the server
I am looking for a way to resize an image client-side with JavaScript (really resize, not just change width and height).
I know it's possible to do it in Flash but I would like to avoid it if possible.
Is there any open source algorithm somewhere…
geraud
- 1,543
- 2
- 10
- 4