W3C home > Mailing lists > Public > www-style@w3.org > September 2011

Re: [css3-background] What does 'border-image-slice: <number>' mean for SVG?

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 12 Sep 2011 02:08:15 -0700
Message-ID: <CAAWBYDB72bMxvFDXqiZ4Mx8c4TWK+_hGqLp8fh384Bqasg3vQA@mail.gmail.com>
To: "L. David Baron" <dbaron@dbaron.org>
Cc: www-style@w3.org
On Sun, Sep 11, 2011 at 9:33 AM, L. David Baron <dbaron@dbaron.org> wrote:
> http://dev.w3.org/csswg/css3-background/#border-image-slice says:
>  # <number>
>  #     Numbers represent pixels in the image (if the image is a
>  #     raster image) or vector coordinates (if the image is a
>  #     vector image).
> I'm not sure what "vector coordinates" are, for example in the case
> of SVG.  I'm guessing that for SVG with a viewBox or with an
> intrinsic size, this means that the image is drawn at its intrinsic
> size and these "vector coordinates" are coordinates in the viewport
> coordinate system.  (But if it has both a viewBox and height/width
> attributes on the root, which win?  Is it CSS pixels on the root's
> container, or the viewport coordinate system?)  It might be good to
> clarify that, though.
> But what happens if the SVG doesn't have an intrinsic size or
> doesn't have a viewBox?  What size is the SVG drawn at in order to
> determine the slices?

SVG always has user coordinates (the lengths referred to when you
provide a number without a unit).  I suspect that's what's meant

For vector images with a defined width/height, such as <svg width=300
height=150>...</svg>, I'm not sure whether it's best to use that size,
or the user coordinates.

Received on Monday, 12 September 2011 09:09:11 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:04 UTC