<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet title="XSL formatting" type="text/xsl" href="http://www.alti.info/feed/rss2/xslt" ?><rss version="2.0"
  xmlns:dc="http://purl.org/dc/elements/1.1/"
  xmlns:wfw="http://wellformedweb.org/CommentAPI/"
  xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
  <title>Alt-I, des informations alternatives - Informatique, Cultures alternatives et Geekeries saupoudrées d'Ajax. - W3C</title>
  <link>http://www.alti.info/</link>
  <description>Alt-I, des informations alternatives. Podcast causant d'informatique généraliste et de cultures alternatives avec un soupçon de XHTML, CSS, AJAX, Javascript, et autres outils web…</description>
  <language>fr</language>
  <pubDate>Fri, 08 Aug 2008 21:16:06 +0200</pubDate>
  <copyright>Creative Commons By-NC-SA</copyright>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Dotclear</generator>
  
    
  <item>
    <title>Coder sur iPhone… encore :p</title>
    <link>http://www.alti.info/post/2008/08/08/Coder-sur-iPhone-encore-webkit-border-image</link>
    <guid isPermaLink="false">urn:md5:2e17439e1a811e43a6299815da8c8ed1</guid>
    <pubDate>Fri, 08 Aug 2008 18:13:00 +0200</pubDate>
    <dc:creator>Hadrien</dc:creator>
        <category>Développement</category>
        <category>Apple</category><category>css</category><category>developpement</category><category>Internet</category><category>iPhone</category><category>Over-Blog</category><category>W3C</category><category>web2.0</category><category>Webkit</category>    
    <description>    &lt;p&gt;Regardez ce genre de design&amp;nbsp;:&lt;/p&gt;


&lt;p&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/OB/Commentaires_Over-blog_iPhone.png&quot; alt=&quot;Commentaires Over-blog iPhone&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;


&lt;p&gt;Pour un navigateur &quot;ancien&quot; (c'est à dire qui ne connaît pas CSS3), réaliser un cadre de ce genre, avec coins arrondis, dégradés, etc, est un très dur labeur. Ça se joue à coup de multiples &amp;lt;div /&amp;gt; imbriqués dont les background sont les coins de l'image savamment découpée, le tout en deux version&amp;nbsp;: une pour IE, la seconde pour les autres… C'est à cause de ça que le web2.0 a beaucoup été designé (du verbe to design :p) à coup d'aplat de couleur.&lt;/p&gt;


&lt;p&gt;Et bien avec Safari 3, finie l'usine à gaz&amp;nbsp;! Une propriété magique, propriétaire pour le moment, mais en cours de validation par le W3C fait des miracles. Il s'agit de &lt;em&gt;-webkit-border-image&lt;/em&gt;.&lt;/p&gt;


&lt;p&gt;Pour faire une bulle comme sur le screenshot, nous n'avons besoin que d'une image&amp;nbsp;:&lt;/p&gt;


&lt;p&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/OB/bubbleWhite.png&quot; alt=&quot;Bulle blanche&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;


&lt;p&gt;Et de la css suivante&amp;nbsp;:&lt;/p&gt;
&lt;pre class=&quot;css&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #6666ff;&quot;&gt;.bulle&lt;/span&gt; &lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;border-width&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;:&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;16px&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8px&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8px&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8px&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	-webkit-border-image&lt;span style=&quot;color: #66cc66;&quot;&gt;:&lt;/span&gt; &lt;span style=&quot;color: #993333;&quot;&gt;url&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #ff0000;&quot;&gt;'bubbleWhite.png'&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;16&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;8&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/pre&gt;


&lt;p&gt;Appliqué au XHTML suivant&amp;nbsp;:&lt;/p&gt;
&lt;pre class=&quot;html&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&lt;a href=&quot;http://december.com/html/4/element/div.html&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;lt;div&lt;/span&gt;&lt;/a&gt; &lt;span style=&quot;color: #000066;&quot;&gt;class&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: #ff0000;&quot;&gt;&amp;quot;bulle&amp;quot;&lt;/span&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	Je suis dans une bulle \o/&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/pre&gt;


&lt;p&gt;Et c'est tout. La bulle pourra s'agrandir en hauteur et en largeur sans aucun étirement ou décalage.&lt;/p&gt;


&lt;p&gt;Comment cela fonctionne-t-il&amp;nbsp;?&lt;/p&gt;


&lt;p&gt;On définit tout d'abord l'épaisseur de chaque bordure du cadre :&lt;br /&gt;
border-width: haut droite bas gauche;&lt;br /&gt;
Dans mon cas, la bordure du haut sera plus épaisse car il faut y faire rentrer la flèche de la bulle.&lt;/p&gt;


&lt;p&gt;Ensuite, on indique quelles zones de l'image de fond seront appliquées dans les bordures :&lt;br /&gt;
-webkit-border-image: url('bubbleWhite.png') haut droite bas gauche;&lt;br /&gt;
On prends la zone de l'image de 0px du haut à 16px et on la met sur la bordure du haut, la zone de 0 pixel de droite à 8px et on la calle à droite, etc. Tout le reste fait partie du centre du contenant qui s'étirera selon le contenu. Tout ce qui est dans les bordure gardera sa taille initiale.&lt;/p&gt;


&lt;p&gt;Les zones rouges sont les parties de l'images qui seront placées en tant que bordure, le reste sera étirée en tant que background&amp;nbsp;:
&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/OB/bubbleWhiteSchema.png&quot; alt=&quot;Bulle blanche schématisée&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;



&lt;p&gt;C'est magnifique&amp;nbsp;!&lt;/p&gt;</description>
    
    
    
          <comments>http://www.alti.info/post/2008/08/08/Coder-sur-iPhone-encore-webkit-border-image#comment-form</comments>
      <wfw:comment>http://www.alti.info/post/2008/08/08/Coder-sur-iPhone-encore-webkit-border-image#comment-form</wfw:comment>
      <wfw:commentRss>http://www.alti.info/feed/rss2/comments/326</wfw:commentRss>
      </item>
    
  <item>
    <title>Coder pour l'iPhone</title>
    <link>http://www.alti.info/post/2008/08/01/Coder-pour-iPhone-safari-mobile-webkit-css3</link>
    <guid isPermaLink="false">urn:md5:ec5aa71ebf816ec30994af7d45372624</guid>
    <pubDate>Fri, 01 Aug 2008 21:09:00 +0200</pubDate>
    <dc:creator>Hadrien</dc:creator>
        <category>Développement</category>
        <category>Apple</category><category>css</category><category>developpement</category><category>iPhone</category><category>Safari</category><category>W3C</category><category>web2.0</category><category>Webkit</category>    
    <description>    &lt;p&gt;&lt;img src=&quot;http://trac.webkit.org/chrome/site/icon.png&quot; alt=&quot;Webkit&quot; style=&quot;float:left; margin: 0 1em 1em 0;&quot; /&gt;…c'est fantastique. Je parle de web dev pour Safari Mobile, pas du SDK Cocoa touch.&lt;/p&gt;


&lt;p&gt;Quand on dev du web de façon classique, c'est à dire en privilégiant IE, puis Firefox, et éventuellement si on a le temps, Safari et Opéra, on est obligé d'utiliser les même technos de 5 ans d'âge, de passer du temps à faire des version différentes pour IE qui ne respecte rien, même pas ses propres standards proprios. Obligé de faire des design laids, car IE6 ne sait pas gérer le PNG24, impossible de s'amuser avec les fantastiques CSS3 que seul Safari gère pour le moment.&lt;/p&gt;


&lt;p&gt;L'iPhone utilise donc Safari, le navigateur le plus en avance technologiquement. En plus des CSS3, il inclue des propriétés CSS (propriétaires, ok, mais proposées au W3C pour compléter CSS3) très pratiques qui permettent de gagner un temps fou pour faire des choses, qui nécessitent l'utilisation de grosses librairies Javascript pompant la CPU sur les autres navigateurs.&lt;/p&gt;


&lt;p&gt;Parmi celles-ci, on trouve &lt;em&gt;-webkit-transition-property&lt;/em&gt; et &lt;em&gt;-webkit-transition-duration&lt;/em&gt;. Ces deux propriétés CSS permettent de réaliser des transitions en une seule ligne de code JS. Sur les autres navigateurs, il faut définir des intervalles qui vont éxécuter les étapes de l'animation toute les 10 millisecondes, procédé chiant à coder (heureusement il y a des librairies qui aident à faire ça facilement). Avec Safari, il suffit de préciser dans la feuille de style quelle est la propriété qui devra produire une animation et sa durée. Ensuite, dès que cette propriété est modifiée par javascript (par changement de la variable style ou par changement de classe), la propriété subira une transition d'une fluidité parfaite.&lt;/p&gt;


&lt;p&gt;Exemple&amp;nbsp;:
CSS&amp;nbsp;:&lt;/p&gt;
&lt;pre class=&quot;css&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #6666ff;&quot;&gt;.panel&lt;/span&gt; &lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;width&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;:&lt;/span&gt; &lt;span style=&quot;color: #933;&quot;&gt;100px&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	-webkit-transition-property&lt;span style=&quot;color: #66cc66;&quot;&gt;:&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;width&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	-webkit-transition-duration&lt;span style=&quot;color: #66cc66;&quot;&gt;:&lt;/span&gt; 1s&lt;span style=&quot;color: #66cc66;&quot;&gt;;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/pre&gt;


&lt;p&gt;XHTML&amp;nbsp;:&lt;/p&gt;
&lt;pre class=&quot;html&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&lt;a href=&quot;http://december.com/html/4/element/div.html&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;lt;div&lt;/span&gt;&lt;/a&gt; &lt;span style=&quot;color: #000066;&quot;&gt;class&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: #ff0000;&quot;&gt;&amp;quot;panel&amp;quot;&lt;/span&gt; &lt;span style=&quot;color: #000066;&quot;&gt;id&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: #ff0000;&quot;&gt;&amp;quot;panel&amp;quot;&lt;/span&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;	kikoo&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/pre&gt;


&lt;p&gt;Javascript&amp;nbsp;:&lt;/p&gt;
&lt;pre class=&quot;javascript&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: 'Courier New', Courier, monospace; font-weight: normal;&quot;&gt;document.&lt;span style=&quot;color: #006600;&quot;&gt;getElementById&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #3366CC;&quot;&gt;'panel'&lt;/span&gt;&lt;span style=&quot;color: #66cc66;&quot;&gt;&amp;#41;&lt;/span&gt;.&lt;span style=&quot;color: #006600;&quot;&gt;style&lt;/span&gt;.&lt;span style=&quot;color: #006600;&quot;&gt;width&lt;/span&gt; = &lt;span style=&quot;color: #3366CC;&quot;&gt;'500px'&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/pre&gt;


&lt;p&gt;Le conteneur va s'agrandir progressivement de 100px à 500px en 1 seconde, avec une parfaite fluidité.&lt;/p&gt;


&lt;p&gt;Pour conclure, c'est vraiment très agréable de pouvoir utiliser les dernières technologies web sans se prendre la tête en voyant un résultat tel qu'on l'a imaginé dès le premier jet, sans retouche. Si Safari était le navigateur le plus utilisé, le métier de web développeur serait tellement beau…&lt;/p&gt;


&lt;p&gt;&lt;a href=&quot;http://webkit.org/blog/138/css-animation/&quot; hreflang=&quot;en&quot;&gt;Plus d'infos et des exemples&lt;/a&gt;&lt;/p&gt;</description>
    
    
    
          <comments>http://www.alti.info/post/2008/08/01/Coder-pour-iPhone-safari-mobile-webkit-css3#comment-form</comments>
      <wfw:comment>http://www.alti.info/post/2008/08/01/Coder-pour-iPhone-safari-mobile-webkit-css3#comment-form</wfw:comment>
      <wfw:commentRss>http://www.alti.info/feed/rss2/comments/322</wfw:commentRss>
      </item>
    
  <item>
    <title>Acid test 3</title>
    <link>http://www.alti.info/post/2008/02/14/Acid-test-3</link>
    <guid isPermaLink="false">urn:md5:5ec81d010fb7877164a2fc8e374a0fd1</guid>
    <pubDate>Thu, 14 Feb 2008 10:51:00 +0100</pubDate>
    <dc:creator>Hadrien</dc:creator>
        <category>IE SUX</category>
        <category>Apple</category><category>Firefox</category><category>IE</category><category>Microsoft</category><category>Mozilla</category><category>standards</category><category>W3C</category><category>web</category><category>Webkit</category>    
    <description>    &lt;p&gt;On va encore se marrer. &lt;a href=&quot;http://acid3.acidtests.org/&quot; hreflang=&quot;en&quot;&gt;L'Acid test version 3&lt;/a&gt; a été testé sur tout les navigateurs du marché. Voici ce qui devrait s'afficher sur un navigateur respectant les standards à 100%&amp;nbsp;:&lt;/p&gt;


&lt;p&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/.Acid_test_3_reference_s.jpg&quot; alt=&quot;Acid test 3 reference&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;


&lt;p&gt;Malheureusement, on est loin du compte. Seule la dernière nightbuild de WebKit atteind un score respectable de 82%&amp;nbsp;:&lt;/p&gt;


&lt;p&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/.WebKit-r30191_s.jpg&quot; alt=&quot;Acid test 3 WebKit&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;


&lt;p&gt;Et marrons nous devant IE6 et IE7&amp;nbsp;:&lt;/p&gt;


&lt;p&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/.800px-Acid3_ie6_s.jpg&quot; alt=&quot;Acid test 3 IE6&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;img src=&quot;http://www.alti.info/images/Scrinchoutes/.800px-Acid3_ie7_s.jpg&quot; alt=&quot;Acid test 3 IE7&quot; style=&quot;display:block; margin:0 auto;&quot; /&gt;&lt;/p&gt;


&lt;p&gt;Voilà, avec 70% de navigateurs qui n'arrive même pas à 15% d'un test de standards, le web est mal barré…&lt;/p&gt;</description>
    
    
    
          <comments>http://www.alti.info/post/2008/02/14/Acid-test-3#comment-form</comments>
      <wfw:comment>http://www.alti.info/post/2008/02/14/Acid-test-3#comment-form</wfw:comment>
      <wfw:commentRss>http://www.alti.info/feed/rss2/comments/242</wfw:commentRss>
      </item>
    
</channel>
</rss>