Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

code standards for smilies?

 
Bert Bates
author
Sheriff
Posts: 8898
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a nagging suspicion that this might have been discussed a while back - but what the heck, it's MD.

If you're using smilies in an environment that, unlike JavaRanch, doesn't convert them (in other words a colon followed by a right paren doesn't turn into a yellow smiley face), how do you handle the situation when you want your smily inside a parenthetical clause?

Assume that "x)" is a smiley, what do you think of these?:

1 - What's the difference (wait for it x) ), between a duck?
2 - What's the difference (wait for it x)), between a duck?
3 - What's the difference [wait for it x)], between a duck?
4 - What's the difference (wait for it x), between a duck?
5 - What's the difference {wait for it x)}, between a duck?

Others?

(BTW, a well known wag recently commented "The baby Jesus cries when parens are unbalanced" )
[ February 22, 2008: Message edited by: Bert Bates ]
 
Gabriel Claramunt
Ranch Hand
Posts: 375
Monad Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I usually go for option 1, but always with a feeling that something is not quite right
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64837
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the smiley actually contains a closing parenthesis -like :-) but unlike :-( - then I go for #4. Otherwise #1.
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You mean  ?

option 1 for me.
 
fred rosenberger
lowercase baba
Bartender
Posts: 12124
30
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is a guy in my office who writes his smiles left-handed. For example"

(-;

this would eliminate the confusion when it comes at the end of a parenthetical:

What's the difference (wait for it (x ), between a duck?

however, it always throws me for a loop when i see it wherever it is.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34410
346
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I try to avoid that situation altogether, so I don't have a personal standard. I usually do either #1 or #3 when I need to.
 
ankur rathi
Ranch Hand
Posts: 3830
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Option 2.

My logic is, why do we need extra space (or where it comes from) #1? Why to switch to angle bracket or curly braces #3 and #5? Where is closing parenthesis #4?

And why to think a simile is special. Let�s consider it text.
 
Marc Peabody
pie sneak
Sheriff
Posts: 4727
Mac Ruby VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I used to do option 1 but now I prefer not to repeat characters (and do option 4 ;)
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Option 1
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm a frequent user of both smilies and parentheses, but I'd consider just dropping the smilie when they intersect. Otherwise I would most commonly use

6 - What's the difference (wait for it), x) between a duck?

To be fair I usually am in an environment that does convert smilies to a graphic when I do that. But I would still prefer to move the smilie away from whatever punctuation is confusing the issue.
 
Michael Ernest
High Plains Drifter
Sheriff
Posts: 7292
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
option 7

What's the difference -- wait for it -- between a duck?
 
Bert Bates
author
Sheriff
Posts: 8898
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I gotta say, in my book Michael scores with a big sideways leap
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic