samsung – Why does my application look bigger / smaller on different phones when I use dp and sp as a unit?

My application looks bigger / smaller on different devices and I could not figure out why. After some research, I found the Android Developer Guidelines for supporting different screen sizes. It is suggested to use dp / sp instead of px as the unit of measurement, which I have already done.

I tested my app on two phones with a screen of 5 "7. The first was the Google Nexus 5X, which ran API 28 on an emulator, where it looked like intended, then I tested it on a Samsung Galaxy 5 in physically and in each The item looked a lot bigger, so big that the app did not fit on the screen.

I want to know why this happens and how I can solve it.

Here is a part of my code



    

        

        

        

        

        

        
    



My app has a set of maps in a HorizontalScrollView (dynamically generated by code) and a button at the bottom of the screen. The button is the element that leaves the screen as the other elements of the activity become larger.

Calculus – The detection of an integral is smaller than the parameter

$$ R = int_s ^ t frac {1} { sqrt {(x + a ^ 2) (x + b ^ 2) (x + c ^ 2)}} dx $$

a, b, c parameters.
Prove that the integral between $ s = 0, t = 1 $ is $ le frac {1} {abc} $

my try: that's obvious $ sqrt {(x + a ^ 2) (x + b ^ 2) (x + c ^ 2)} ge sqrt {a ^ 2b ^ 2c ^ 2} $ and therefore $$ int_0 ^ 1 frac {1} { sqrt {(x + a ^ 2) (x + b ^ 2) (x + c ^ 2)}} dx le int_0 ^ 1 frac {1 } { sqrt {a ^ 2b ^ 2c ^ 2}} dx = int_0 ^ 1 frac {1} { sqrt {a ^ 2} sqrt {b ^ 2} sqrt {c ^ 2}} dx = int_0 ^ 1 frac {1} {abc} dx $$

Is that what is needed?

Do smaller openings offer more depth of field than the diffraction limit, even if the sharpness of the tip suffers?

Especially that was an issue in the movie. If Bryan Peterson did not know about it at the time, it just shows what he did not know. Not that it was not really a problem

There were differences, however. First, we did not have EXIF ​​data, and most people did not keep the notes accurate enough to really know why shot X was a bit sharper than shot Y. Even for those who took notes, they did real tests, you For example, you can take 100 shots of the same subject and vary the camera settings to see what works well and what was not enough work very Few people really tried.

Second, the standards were much lower for most people. In particular, viewing images on a computer monitor does it a lot of It's easier to zoom in on the view so that there are really smaller errors that you would never see in a print of adequate size or by projecting a slide Really large

Third, a psychological effect is involved. If you shoot at f / 22, everything is a little blurry, so you (for example) do not look at it that closely. Most people will never really notice because they tend to look more closely when they realize (mostly unconsciously) that there are no details to see. In contrast, if you record at f / 5.6 the parts of the picture that have exactly the same CoF size as f / 22 appearance out of focus, because you (at least usually) see parts that are much sharper.

Fourth, much depends on the quality of the affected lens. If you're 50 or 60 years old with lenses like 50 years before the game, you can count on them to be pretty dreadful by today's standards when they're wide open. An f / 2 lens may need to be slightly shut down to f / 8 before it is straight quite Good for modern standards. The wide open deviations were so bad enough that in many cases the quality still improved by f / 11 or even f / 16. A great lens and a really bad lens are about the same at f / 22, but at f / 8 the big lens is on amount better.

To get closer to your direct question: Yes, the sensor size has a significant impact. With a larger sensor you need to be closer to the subject to get the same image setting with the same focal length of the lens. This means that a larger sensor will normally reduce the apparent DoF so you can do more by stopping. Secondly, if you are using a larger sensor, you increase the size of the sensor to get the same print size. This prevents the loss of sharpness in a small aperture being almost as obvious.

To give an extreme example, many of the best-known "classic" photographers, including Adams and Weston, belonged to what they called the F / 64 club. Take a 8×10 camera (or even bigger) required a tiny aperture to ever get a DoF, and (obviously enough of the name) considers f / 64 as the ideal aperture. The loss of sharpness did not matter much, for the simple reason that he rarely grew much larger. Starting from a 8×10 negative, even a 24×30 print was only a 3: 1 magnification – slight Fewer Magnification than creating a 3×5 print from a digital full-screen camera.

Edit: First, f / 22 is rarely necessary from DoF's point of view. Consider hyperfocal distances for a 50mm lens at different openings:

f / 8: 41 feet
f / 11: 29 feet
f / 16: 21 feet
f / 22: 15 feet

The nearest point in focus is in any case half that number. So if you go from aperture 16 to aperture 22, you get about 3 feet of foreground in the foreground. There are undoubtedly times that it's almost worth to gain 3 feet something, Let's face it, it's not really common – and in 95% of cases where you can use the f / 22 function, you can use (for example) Focus Stacking to do the same and overall much higher sharpness.

For a typical landscape it is not necessary at all. For example, consider an FF camera with a 50mm lens that is held at eye level (eg, 60 "above the ground), and the near ground is roughly flat and level, for the sake of simplicity we assume that the camera is kept roughly level.

In this case, the nearest foreground is at very The edge of the image is about 250 inches (just under 21 feet) away. F / 8 is small enough for that all Picture falling in the DoF. Someone looks like Really close to the very The edge of the image may be able to tell that it's just a little bit softer than the middle – but what you see is a bit sharper on the edge and a amount Sharper in the middle than if you had taken the shot at f / 22.

However, I feel obliged to add that DoF is not the only reason to use a tiny iris. Sometimes I use a tiny aperture to get a rather soft, low-contrast image. Setting f / 22 (or f / 32 if available) can be a really cost effective alternative to a soft focus object. If you want to have a soft, dreamy look that you expect from a pinhole camera, f / 32 can be an easy replacement task.

Conclusion: It is quite possible to create some really nice pictures by taking photographs with f / 22 or f / 32 – but if / when you use it, you should do so at least on the basis of an idea of ​​what to expect , I want to know the kind of picture you get. Do Not Do it because Bryan Peterson (or anyone else) has assured you that it's the right thing to do, and you should not expect a picture at f / 22 to be as sharp as one on f / 11.

Let me close with a short series of pictures. These were all taken by a tripod with a toughened mirror, all within a few seconds, so that the light has changed very little, etc. First, a complete shot:

Enter the image description here

Then 100% harvest at f / 11, f / 16, f / 22 and / f32:
Enter the image description hereEnter the image description hereEnter the image description hereEnter the image description here

Well, it's true that we peep at least some degree here, but it's also true that the quality loss at f / 22 and (especially) f / 32 is pretty obvious. Although most tests show a loss of f / 16 in flat, high-contrast targets, here on a real picture, f / 16 does not show too much of f / 11.

OTOH, at f / 22, is pretty noticeable, and at f / 32, the result is frankly horrible.

Oh, and these are all taken at 200mm. If you believe that a long lens will save you from the effects of diffraction, prepare for some disappointment …

Website Design – How do you resize text and / or elements to make smaller screens?

I have a layout that I created some time ago in Adobe XD (that was just a personal project), and now I want to put it on Behance. To do this, I need to copy / paste this layout (for desktop) to smaller screens, iPad, and mobile devices.

Since I'm not used to designing for smaller screens, I have a doubt after launching: how do I know, for example, how much I need to reduce the size of text and UI elements? To explain it better: I have a text with 40px. How should I expect to reduce this size properly? Is there a pre-set percentage to reduce these values? Maybe some visual "standard" rules that every design follows?

I'm always designing for Bootstrap, but I'm not sure if I think right.

(I also wrote this on stack overflow, I'm not sure which one is best for my question).

Thank you for all your thoughts and advice that you could tell me. Most of the time I worked for desktops, a traditional web designer, and now I'm trying to migrate to UI / UX.

np complete – If a problem is more difficult, is the language it represents smaller?

I read the definition of reducible polynomial time:

To let $ L_1, L_2 $ be two languages ​​Ob $ L_1 $ is to reduce polynomial time down to $ L_2 $ then exists $ f: {0,1 } ^ * $ s.t. $ forall x in {0,1 } ^ * $ $$ x in L_1 iff f (x) in L_2 $$

For me that means that $ L_1 $ can be greater (in cardinality) than $ L_2 $, but $ L_2 $ is more difficult there $ L_1 $ can be solved after $ L_2 $?

My Landing Page: I think it's not too friendly with smaller screens

I've created a landing page for my site that looks good so far. However, when resizing my browser, I noticed that things are moving in ways they should not. To my understanding, I can have a mobile, user-friendly version that is used separately CSS but I'm not so sure.

I have some questions that I would like to read in the reviews:

  • What should I think about friendliness on multiple platforms?
  • I have seen px, em, and vw Represent sizes; Which is the professional standard?
  • Does the layout seem to be simple overall?
  • Is there a smarter way to accomplish what I did?
    • Smart does not mean being smarter, but has to be entertained with low to medium skills.

Feel free to see this on codepen to get better visuals. The use of the built-in display clearly shows the movement of the elements that I have described before.

Body {
Background color: #FFF;
Color: # 333;
}
.global-nav {
Position: fixed;
below: 0;
Width: 100%;
Border Top: 1px fixed #CCC;
}
.global-nav li {
Display: inline block;
Upholstery left: 9%;
Character spacing: 5px;
Text transformation: uppercase letters;
}
.global-nav a {
Text decoration: none;
Color: # 333;
}
.global-nav a: hover {
Color: # 3AF;
Transition: 0.5s color;
}
Title
Width: 50%;
Margin: car;
Text transformation: uppercase letters;
}
title h1 {
Font size: 125px;
Margin: 0;
}
Title h2 {
Font size: 75px;
Margin: 0;
}
.title span {
Font size: 25px;
}
.title a {
Color: # 3AF;
}

Perpetual J

Studios

This website is up to date under construction.

Tiles – Funded smaller pictures

I found CSS code that makes my transported link tiles smaller. However, the images are not always resized. Some images are resized and others do not understand why.

This is how it looks like:
Enter the image description here

This is the code I found. It wraps all the tiles and makes them smaller. (110px)


Edit: It is not important for the "Publish to Office" and "Learn Developer Site" tiles. It looks like they're on a sprite sheet and I do not use spritesheets in my final code, but individual pictures. So I'm wondering why the only picture "Test my pics" is strangely cut off. In the code the height seems to be 150px and the width is 100. If all others are 100x100px.

EDIT2: God damn, I'm stupid, I just added in my CSS to fix that

#promotedlinkID img {
right: 0px;
Width: 100px;
Height: 100px;
}

Algorithms – For loop area with smaller number on the right side

Some of your previous answers have not been well received and you run the risk of being blocked from answering.

Please note the following notes exactly:

  • Please be sure answer the question, Enter details and share your research!

But avoid

  • Ask for help, clarification or answering other answers.
  • Make statements based on opinions; secure them with references or personal experiences.

For more information, see our tips for writing great answers.

Web App – How to deal with components in a responsive design that are larger at smaller breakpoints?

It should be noted that I use heuristics for the screen size to estimate the height of the viewport based on the width to simplify the presentation. This may be a faulty heuristic and it may be better to use a height query instead of a width query for full accuracy. The problem will exist in both methods

Another note is that the banners and navis described must be static elements. Once they are displayed, you will not be able to scroll through them.

I have a web app design that is very sensitive to vertical space (support users with a resolution of 1024 x 768 minus browser chrome). For technical reasons, two navigation elements are required.

A third banner component needs to be added to the screen in certain contexts. Given this sensitivity, I would like to include the component in the top navigation as soon as horizontal space allows it

(I have removed identifiable elements)

Navigation at 320

At the smallest breakpoint there is not enough horizontal space to place the banner in the top navigation, and we have to do it. It's alright, you're not so vertically challenged at these latitudes because you're probably in portrait mode.

At the next breakpoint, it becomes possible to place the component in the top Navi:

Navigation at 578

The pressure on vertical real estate is increasing as you are likely to be in a landscape / 4: 3 environment at this size and are now forced into vertical space.

At first glance everything seems to be alright. The component fits and is slightly larger than at breakpoint 320.

However, the entire app is fluent and so the breakpoint of 320 is also provided at 500 or at 577. In these situations, the space available for the banner is much larger than just a 1-pixel enlargement of the viewport.

At 550, for example, the banner could be 518 wide, but if we increase the display area to 600, the banner is suddenly only 328 wide.

And this becomes a challenge, since the banner actually has a dynamic ad and is much more usable at 550 than at 328. I'm relying on usability in a different direction in one direction.

((e: it's usable in any size, but of course, if we get more space it's nicer, the banner has a minimum standard for information, and the result can be compressed.)

I can not be the only person who has encountered this problem (responsive nav does this again and again, but in these cases the extra width is not used to the extent that the banner component is here).

Any advice or guidance from experience or any other reason to help me with this problem?

Am I just keeping the banner under?
Do I prevent the full banner experience at the bottom breakpoint to improve the progressive expansion at a larger breakpoint? (No)
I just accept that while trying to take into account these competing sensitivities, which must be something, and as long as the banner is usable, these marginal cases are just one thing that happens.

Cheers for the input.