Re: macbook retina support

2012-08-15 Thread Christian Riedel
Having all @media switches in one css file might make your mobile clients download a lot of useless rules. You can split the files up and include just those files that are applicable for the device that is loading your pages. Check out this project: https://github.com/scottjehl/eCSSential#check

Re: macbook retina support

2012-08-15 Thread sommeralex
the window device ratio was the wrong example (due it is JS) apple mentions two others ways, but it seems they are "CSS" solutions header { background: -webkit-image-set( url(images/header.jpg)1x, url(images/header_2x.jpg) 2x); height: 150px; /* heig

Re: macbook retina support

2012-08-14 Thread Thiago H de Paula Figueiredo
On Tue, 14 Aug 2012 21:23:09 -0300, sommeralex wrote: the only thing this binding should do is 1. to check if the window.devicePixelRatio >= 2 and if, check if a my_2x.png pic exists on the same location has the my.png - and if so, it should take the _2x.png The binding code is complet

Re: macbook retina support

2012-08-14 Thread sommeralex
i would prefer to write a "binding" like src="${context:/img/my.png}" but as some poster has mentioned before named "retina" so i can use it that way: "${retinaContext:/img/my.png}" the only thing this binding should do is 1. to check if the window.devicePixelRatio >= 2 and if, check if a my_2x.

Re: macbook retina support

2012-08-13 Thread Thiago H de Paula Figueiredo
On Mon, 13 Aug 2012 13:09:03 -0300, sommeralex wrote: Hello! Hi! The apple doc describe 3 ways for supporting retina images. My question, before i start to replace everything with javascript or css, is, if there will be an update of tapestry supporting the automatic retina with this synta

Re: macbook retina support

2012-08-13 Thread Thiago H de Paula Figueiredo
On Mon, 13 Aug 2012 13:34:16 -0300, sommeralex wrote: and where is the documentation to write custom bindings? :-) We already know that the Tapestry documentation needs to be improved. ;) Please fill a documentation JIRA when you find something like that. ;) -- Thiago H. de Paula Figuei

Re: macbook retina support

2012-08-13 Thread Christian Riedel
A few days ago I made a little tapestry-add-on to support a json-binding. Just have a look at the sources and you'll know how to implement the equivalent for your use-case! https://github.com/criedel/tapestry-json-binding Best Christian Am 13.08.2012 um 18:09 schrieb sommeralex: > Hello! > >

Re: macbook retina support

2012-08-13 Thread sommeralex
and where is the documentation to write custom bindings? :-) 2012/8/13 Lance Java [via Tapestry] < ml-node+s1045711n5715343...@n5.nabble.com> > You could write your own custom binding prefix. > > Eg src="${retina:/foo/bar.png}" > > See here for custom binding prefix examples > wiki.apache.org/tap

Re: macbook retina support

2012-08-13 Thread Lance Java
You could write your own custom binding prefix. Eg src="${retina:/foo/bar.png}" See here for custom binding prefix examples wiki.apache.org/tapestry/Tapestry5HowTos On Monday, 13 August 2012, sommeralex wrote: > Hello! > > The apple doc describe 3 ways for supporting retina images. My question,