screen-resolution

How do I set browser width and height in Selenium WebDriver?

99封情书 提交于 2019-11-27 12:58:52
I'm using Selenium WebDriver for Python. I want instantiate the browser with a specific width and height. So far the closest I can get is: driver = webdriver.Firefox() driver.set_window_size(1080,800) Which works, but sets the browser size after it is created, and I want it set at instantiation. I'm guessing there is an approach along the lines of: profile = webdriver.FirefoxProfile(); profile.set_preference(foo, 1080) driver = webdriver.Firefox(profile) But I don't know what foo would be, and I can't figure out where the docs are. Q1: is there a way to set width / height at instantiation? Q2:

How to get screen resolution of your android device..? [duplicate]

我是研究僧i 提交于 2019-11-27 12:56:47
问题 This question already has an answer here: How to get screen dimensions as pixels in Android 39 answers Can i get resolution of android phone..? if yes then how..? it will really helpful for me.. Thank you.. 回答1: If you want the display dimensions in pixels you can use getSize: Display display = getWindowManager().getDefaultDisplay(); Point size = new Point(); display.getSize(size); int width = size.x; int height = size.y; This method was introduced in Android API 13, so if you want to get

Only use XHDPI drawables in Android app?

自作多情 提交于 2019-11-27 11:26:19
If you're planning to support LDPI, MDPI, HPDI, and perhaps XHDPI in the near future, is it ok to only include XHDPI drawables in the project and let the devices scale them to their desired resolution? I've tested to resize the drawables into MDPI and HDPI in Photoshop and then compared the result with XHDPI drawables only resized by Android, and I can't see any difference at all. Is it bad design to take this shortcut? It would be nice to not have to resize each and every drawable into 3 different resolutions. Planning to use target SDK is 2.1 or 2.2. BR Emil I guess that's a good way to go.

Switch android x86 screen resolution

风格不统一 提交于 2019-11-27 09:59:52
I would like to use Android-x86 2.2 as an emulator on my Windows 7. I have downloaded VirtualBox and the ISO, and I've made a virtual machine with it, but I can't set the resolution to 320x480 or something similar. The following tutorial " Using the Android-x86 Port as your Emulator " suggests to insert: <ExtraDataItem name="CustomVideoMode2" value="320x480x16" /> to my .vbox file and I did it. Then I added UVESA_MODE=320x480 and vga=ask to the boot config. When it boots, I have to press Enter to see the available options, but there is no 320x480 among them. How can I get it to work? To change

Is it bad to work with pixels in CSS? [closed]

二次信任 提交于 2019-11-27 09:55:15
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 7 years ago . Is it bad in terms of compatibility to use pixel numbers in CSS instead of percentages? How about lower resolutions? Is it okay to

Android supporting multiple resolution with multiple layout folder

别来无恙 提交于 2019-11-27 09:10:45
Now I'm supporting multiple resolution with multiple layout folders. I'm using android development studio and I made 3 different folders. layout layout-large-port-1280x720 layout-normal-port-800x480 and I tested on 800x480 and 1280x720. 480x800 worked well, but 1280x720 follow 800x480 folder's dp and UI. I don't know why this thing happens to me and I don't know how to solve the problem. Why it doesn't work and what should I have to do? For Different screen size, The following is a list of resource directories in an application that provides different layout designs for different screen sizes

android live wallpaper rescaling

故事扮演 提交于 2019-11-27 08:59:46
I am learning how to make live wallpapers, but I have a dilemma I'm sure all who start off have as well. There is so many resolution screen sizes, how can I just make one set of artwork to be rescaled in code for all versions? I know it's been done as I seen the images in the apk's on a lot of them and they get rescaled. If it was just one image that did not need any positioning that would be easy, but my problem is I have to get the background image rescaled to fit all devices, I also have animations that fit in a certain x and y position on that background image to fit in place so it looks

Most popular screen sizes/resolutions on Android phones [closed]

百般思念 提交于 2019-11-27 08:55:54
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 2 years ago . I understand that Android's developer site provides information on this topic. I have already read the following three pages: Supporting Multiple Screens Screen Sizes and Densites Icon Design Guidelines They do not give the information/statistics that I am looking for.

Android studio selecting wrong layouts

大憨熊 提交于 2019-11-27 08:39:48
问题 I am new to Android. I am building my first application. I have been trying to make it support multiple screens. I have gone through the developers section in android, but, I am not clear at these things. What is the resolution, I should use for the different drawable folders? (for example an hdpi screen may have 500*600 screen or 1280*1920 screen.) I have been using layout folders as mentioned in the developers page, like small, normal and the rest, but android keeps on selecting normal

Change screen resolution in Java

南笙酒味 提交于 2019-11-27 08:21:47
问题 I have a program that uses visual scripting (sikuli-script) to allow the users to create their own visual scripts. The program needs to work across multiple systems that could have different screen resolutions. Sikuli matches highlighted images on a pixel-by-pixel basis, so on systems with different resolutions will fail to find images. Therefore is there a way that I can change the resolution settings in windows through java code? Going full-screen is not an option as images that need to be