W3C home > Mailing lists > Public > www-style@w3.org > June 2014

Re: Background image cropping

From: Marat Tanalin <mtanalin@yandex.ru>
Date: Tue, 10 Jun 2014 19:16:17 +0400
To: Dirk Schulze <dschulze@adobe.com>, Tab Atkins Jr. <jackalmage@gmail.com>
Cc: Lajos Koszti <ajnasz@ajnasz.hu>, www-style list <www-style@w3.org>
Message-Id: <171531402413377@web4j.yandex.ru>
10.06.2014, 18:44, "Dirk Schulze" <dschulze@adobe.com>:
> I believe Mozilla has a -moz-image-rect() [1] image function that clips the input image argument. It is not specified though.
>
> Dirk
>
> [1] https://developer.mozilla.org/en-US/docs/Web/CSS/-moz-image-rect

By the way, Mozilla's `-moz-image-rect()` functional notation looks much better than Media Fragments in CSS for several reasons:

    * Media Fragments spec unreasonably tries to reuse anchor/hash
      part of the URL for something that has _nothing to do_ with
      anchor/hash and therefore is potentially confusing;

    * functional notation looks more readable/intuitive than
      `xywh`-like stuff used in Media Fragments;

    * functional notation looks more flexible as for ability to mix
      different units for different dimensions and also to use `calc()`
      function for a single dimension value.

Since there are no implementations of Media Fragments in CSS, it may make sense to drop trying to apply Media Fragments to CSS in favor of a functional notation similar to `-moz-image-rect()`.

Thanks.
Received on Tuesday, 10 June 2014 15:16:51 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:22 UTC