Fingerprints

When I design, I tend to attempt the shorthand methods of CSS which means that I use margin: 2px 4px 1px 3px; instead of writing each margin out. Of course, to prevent confusion (in myself), I tend to use my monitor to remember the order. So if you ever walk in my house and find me touching my monitor in the order of top-right-bottom-left, you’ll know why!

(And I hope that I’m not the only one who does odd stuff like that, lol!)

7 Responses to “Fingerprints”

  1. damonz Says:

    Freak! Actually that’s a very good way to remember… but I must ask: “Why?” Why not type them out long-hand? That way there is never any confusion.

    Because I’m very lazy and for me, even though I have to find a system for remembering it, I find it much more simplistic. I really need to learn how to do all the shorter forms of everything so that I can clean up my CSS more.
  2. squiggle Says:

    Because with CSS3, the “long-hand” will start to get phased out. Short-hand was introduced with CSS2 so people would start getting used to it, and will stick around from now on. Mind you, the long-hand version will be around for a very long time still (much like the FONT and CENTER tags,) however more and more developer, such as myself, will use the short-hand version more often.

    Also, programmers are lazy:

    margin-top : 0px;
    margin-right : 0px;
    margin-bottom : 0px;
    margin-left : 0px;

    That’s 78 characters (including the hard returns on each line, and the spaces around the colon, which aren’t required, but that’s how the validator works.) Now short-hand:

    margin : 0px 0px;

    That’s 22 characters. Even if the margin’s were different sizes, forcing you to put all four in when writing short-hand, that’s still another 3 to 5 characters per side. That’s WAY less than the long-hand version. Think of those modem users who will thank you later.

    And denise? May I suggest small sticky notes (or even a piece of tape) on each side of your monitor, with the words ‘top’, ‘right’, ‘bottom’, ‘left’ writtin on them, and directional arrows pointing to the next side you need to go to? (Go ahead, hit me.)

    Lol, actually it’s just an odd thing I do to do it, I know the directions. I’m very physical when I express myself and it comes out when I’m trying to remember things. Carrie probably remembers when I walked around chanting my speech mantra and pointing my fingers around in high school, lol. ;)

    On a side note, can’t you write it even shorter if the margins are all the same? IE: margin: 0px;

  3. Michael Says:

    I’ve only one word for you: clockwise. Heh…

  4. Michelle Says:

    oh thanks! that’s a good hint. i never knew how to remember it myself, now i know the trick. lol

    Woot! I’m glad someone found something useful in my random confession, lol. :) Nice site, btw. You’ve done an impressive job with the layout and styling.
  5. Rachel in Alaska Says:

    ((((WAVE)))

    LOL! Thought you should know that your above comment reminded me that I really should put a *stalk* board back up. ;)
  6. squiggle Says:

    Yes you can write it even shorter if all four sides are the same. You can have one, two, three or all four sides specified:

    margin : 0px;
    – all four sides are 0px

    margin : 0px 5px;
    – top and bottom are 0px, left and right are 5px

    margin : 0px 5px 10px;
    – top is 0px, right is 5px, bottom is 10px, and left is assumed to be 0px because it simply isn’t listed.

    margin : 0px 5px 10px 15px;
    – top is 0px, right is 5px, bottom is 10px, and left is 15px;

  7. Carrie Says:

    Um… :huh: ok…not a single one of this made sense, yet you got a lot of responses from people and not a one of them are clueless…I’m deprived :( LOL, JK…but I still don’t know what all these things mean, hehe.

Leave a Reply