0

Is there a way in CSS to scale down/up all the content (text, buttons, images, padding, margins, etc) that is shown in the browser screen at once in a way similar to what zooming in/out the browser window itself would accomplish?

I am looking for a solution that is compatible with most modern browsers and does not require me to go over a legacy (and ill structured) large CSS style sheet changing fonts and other elements (e.g. padding, etc) by hand.

The solutions in Scale Up/Down all Elements, Images, Text when browser window width is changed do not work for me because either they use the non standard CSS zoom function or I need to reverse engineer the entire legacy CSS style sheet to do what the other answer there proposes.

Is there anything that could be done other than what is described in that question/answers more than 7 years ago? For example, is there a way I can tell (most modern) browsers programatically, e.g., zoom 80% ?

Thank you!

  • Does this answer your question? [How can I scale an entire web page with CSS?](https://stackoverflow.com/questions/1156278/how-can-i-scale-an-entire-web-page-with-css) – Kenny.Harrer Feb 03 '22 at 15:42
  • What happens if you scale the whole lot with a transform? – A Haworth Feb 03 '22 at 15:48
  • @Kenny.Harrer no i do not think that one answers it because either it requires non-standard zoom feature or requires that i go over the whole (large, legacy) CSS style sheet adjusting fonts sizes, paddings, etc by hand.... – Natalio Krasnogor Feb 03 '22 at 17:45
  • @AHaworth yes, I am nudged towards the transform solution... but wondering whether there is any other way perhaps? – Natalio Krasnogor Feb 03 '22 at 17:46
  • Given that zoom isn’t universally implemented possibly not. Is there a problem with transform? – A Haworth Feb 03 '22 at 17:52
  • @AHaworth Yes, the transform is the way to go. Thank you. – Natalio Krasnogor Feb 04 '22 at 09:35
  • 1
    @Kenny.Harrer thank you for your earlier comments. I think i was too quick to dismissed the solution in https://stackoverflow.com/questions/1156278/how-can-i-scale-an-entire-web-page-with-css . You were correct, via transform i can do what i need to do. – Natalio Krasnogor Feb 04 '22 at 09:35

0 Answers0