Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    jkd
    jkd is offline
    Senior Coder jkd's Avatar
    Join Date
    May 2002
    Location
    metro DC
    Posts
    3,163
    Thanks
    1
    Thanked 18 Times in 18 Posts

    Slants without the markup

    The description of this forum says you can post a code snippet, and not necessarily Javascript, so.... here's a nifty CSS effect.
    (Besides, I'm a supermod, so I can do whatever I want, muahahahahaha )

    Alright, here's the deal, the motivation, the result, and the limitations:

    1. Slants. Pretty nifty stuff:
    http://www.infimum.dk/HTML/slantinfo.html

    2. Too bad that pollutes the markup, isn't it? Tantek has made quite a mess in the source with his pretty-looking hexagons.

    3. Look ma! No excess markup!
    http://www.jasonkarldavis.com/slant.xhtml

    4. Oh, I forgot to mention. Opera 7-only. That's a huge limitation right there. I'm not sure about KHTML's rendering, though I doubt it would render it correctly. (If somebody with Safari 1.0 wants to take a screenshot though, that would be cool.) Mozilla puts the slants in; it just doesn't put them in the correct location. There are known bugs in Bugzilla though concerning marker-box insertions, so...

    Anyway, I got around polluting the markup by making use of the :before and :after marker-boxes that CSS2 makes readily available for me.
    Opera has always had the best support of content insertion to my knowledge, followed by Mozilla, and with Safari/Konqueror somewhere in there too. So, even :before and :after is severely limited, and then applying slants limits it even more. I'm still working on making it display in Mozilla though, so who knows; I just might make this remotely useful.

    Anyway, just some more eye candy and food for thought for you guys. I've been trying to post some interesting stuff in this forum lately, in case you didn't notice.

  • #2
    jkd
    jkd is offline
    Senior Coder jkd's Avatar
    Join Date
    May 2002
    Location
    metro DC
    Posts
    3,163
    Thanks
    1
    Thanked 18 Times in 18 Posts
    A hexagon taken from Tantek's website and modified similarly as above to not include extraneous markup.

    http://www.jasonkarldavis.com/hexagon.xhtml

    Works in Mozilla this time too.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •