W3C home > Mailing lists > Public > www-svg@w3.org > December 2014

SVG 2 high value use cases based on StackOverflow questions

From: Paul LeBeau <paul.lebeau@gmail.com>
Date: Thu, 4 Dec 2014 15:37:00 +1300
Message-ID: <CACfsppAfP1Bw35x33--ZEwNht5kVyhQaBDqVYQC-vpqAE5hFEg@mail.gmail.com>
To: www-svg <www-svg@w3.org>
Hi all

I have been following the SVG keyword on Stack Overflow for a while.  There
are a number of things that come up a lot in the questions and I thought it
would be useful to try and put together a list so that these use cases get
due consideration before SVG2 is finalised.

This is an off-the-cuff list.  I am sure I am missing some.  There are a
few others here who regularly monitor SO, so perhaps they will be able to
think of more.

Paul



*viewBox*

ViewBoxes seem to be an endless source of confusion.  Trying to explain how
to calculate a viewBox can be hard.  I think that supporting viewBox="auto"
would be very useful to SVG beginners.


*Vertical centering of text*

People are always wanting to center text in circles and rectangles.  At the
moment there is no reliable way of vertically centering.
 alignment-baseline support is not universal and depends on the font (?),
and doesn't support the most common use case.  Usually people want to
perfectly center the glyph bbox (not the Em box).


*Responsive sites*

This is a biggie.  Common things people want to do when using SVG in
responsive websites include:

- Elements whose scale is not affected by preserveAspectRatio
      - circles that don't squash
      - clipped images - clip squashes but not the image it is clipping
- Patterns that whose scale is not affected by preserveAspectRatio
- Percentage path coordinates

Example:
http://stackoverflow.com/questions/27070929/certain-parts-of-typography-letters-respond-to-width-height-of-window


*Relative positioning*

Another common request is being able to position elements relative to other
elements.  Not sure how I feel about this, but it comes up quite a lot.
People are used to the HTML layout model, I guess.
Received on Thursday, 4 December 2014 02:37:47 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:47:38 UTC