Open Side Menu Go to the Top
Register
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** ** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **

02-15-2016 , 05:34 PM
Quote:
Originally Posted by RogerKwok
2-space indentation seems like a gateway to write super nested code

sure 4 takes more room but it's objectively easier to discern than 2, and if the code isn't over-nested, it's not a big deal
Another thing I look at a lot is Jade files. 4-spaces in that would be a recipe for disaster. So now what do you do when you have a sciptlet inside your jade file?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 05:43 PM
I'm nervous about one of my projects. I've put it on a website sort of for demo purposes, but it looks like it could be a business as well. How do resume sifters and employers feel about this stuff? Will they think I'm just trying to fund my business and quit asap?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 08:38 PM
Quote:
Originally Posted by goofyballer
I, too, like to pretend monitor resolutions haven't increased since the 1980s
haha! Nice


So, uh, chaos happened tonight. More on that later. Too many things to do.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 10:16 PM
Quote:
Originally Posted by gaming_mouse
maybe the peevish tone rubs you the wrong way, but aside from some trivial grammatical errors like comma splices, which don't affect the readability imo, the writing is clear and communicates the author's thoughts and feelings.

it's hard to tell if the complaint is valid or the author just isn't cut out for programming, although barrin's posting it makes me think the latter.
Maybe it's just me, but when I was an undergrad and we had issues understanding something, we either discussed it during tutorials or directly with the prof.

We'd also lose marks for bad grammar, poor spelling and lack of punctuation, but maybe that's a UK thing.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 10:23 PM
Quote:
Originally Posted by econophile
do you ever print out your code? (srs question)
No

But also, we're not talking about dot-matrix 9-pin printers, right? Any modern printer can do way more than 80-character widths. I think of 120 as an absolute minimum, I think I have my editor set to warn at 160.

80 char widths come from a time when we were all programming assembly or C, and monitors literally could only display 80 characters wide.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 10:25 PM
And P.S. a lot of people used 8-character indents in those days.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-15-2016 , 11:49 PM
Quote:
Originally Posted by codeartisan
Maybe it's just me, but when I was an undergrad and we had issues understanding something, we either discussed it during tutorials or directly with the prof.

We'd also lose marks for bad grammar, poor spelling and lack of punctuation, but maybe that's a UK thing.
i'm not defending the post in the larger sense. i just didn't think it was an example of terribly bad writing.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 02:44 AM
Quote:
Originally Posted by gaming_mouse
i just didn't think it was an example of terribly bad writing.
You're right, it's not terribly bad and it did get the point across, it just tilts me having to read such obvious mistakes (random capitalized letters, missing apostrophes, etc).

It also tilts me when working to see words misspelled in variable/function names (or god forbid, the worst possible offense: a class name) and doubly so if it's from someone whose first language is English.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 05:20 AM
Quote:
Originally Posted by RustyBrooks
And P.S. a lot of people used 8-character indents in those days.
No nesting in assembly language programming though.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 07:45 AM
Quote:
Originally Posted by goofyballer
I, too, like to pretend monitor resolutions haven't increased since the 1980s
There's other nice benefits of 80 too.

For instance on a 1080p monitor with a sane font size you can fit 3 code windows side by side if you limit lines to 80 characters. That's a noticeably large win, and that reason alone is enough for me to stick with 80.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 08:20 AM
Quote:
Originally Posted by Shoe Lace
There's other nice benefits of 80 too.

For instance on a 1080p monitor with a sane font size you can fit 3 code windows side by side if you limit lines to 80 characters. That's a noticeably large win, and that reason alone is enough for me to stick with 80.
LLLooonnnggg variable names would tend to stretch code lines past 80 chars. Capers Jones collected data that indicates 10-15 chars is the best. More is better than less. Not knowing anything about JavaScript, it appears that high quality code could easily exceed 80 chars on a line but not sure of that.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 09:14 AM
Quote:
Originally Posted by adios
LLLooonnnggg variable names would tend to stretch code lines past 80 chars. Capers Jones collected data that indicates 10-15 chars is the best. More is better than less. Not knowing anything about JavaScript, it appears that high quality code could easily exceed 80 chars on a line but not sure of that.
I mostly program in Python and Ruby now a days but I can't say that I've been in many situations where I wanted to rename a variable just to fit everything on 1 line.

It happens on very very rare occasions. Without any facts to base this on, 10-15 sounds about right for most of my mine. I usually end up with 1-2 words and make an effort to describe what it's for in the most concise/clear way possible.

The only time where I notice it to be annoying is dealing with HTML templates. I tend to just say fk it in a lot of cases when it comes to HTML, although you can get cute and start adding new lines to break up tags that have a lot of attributes (I find this makes it a lot more readable too).
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 10:52 AM
In a move that should surprise no one, the new version of sourcetree is total crap, don't upgrade until its fixed. And maybe not even then as they removed "open selected" which is all I use it for.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 03:24 PM
Quote:
Originally Posted by Shoe Lace
There's other nice benefits of 80 too.

For instance on a 1080p monitor with a sane font size you can fit 3 code windows side by side if you limit lines to 80 characters. That's a noticeably large win, and that reason alone is enough for me to stick with 80.
Cool, so we've moved on from the 80s to the 90s. My display is something like twice that wide, so i have no problem fitting 3 widths of code and before you ask, no, i don't need 6.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 03:33 PM
Quote:
Originally Posted by RustyBrooks
Cool, so we've moved on from the 80s to the 90s. My display is something like twice that wide, so i have no problem fitting 3 widths of code and before you ask, no, i don't need 6.
90s? I'm not so sure about that. 1080 is the vertical, the full resolution is 1920x1080.

Twice that would mean you're sporting a 4k monitor, which is entirely feasible but I'd be surprised if you had that screen real estate in the 90s. I mean, I had a pretty good NEC CRT back in the day and it topped out at 1600x1200, but it was able to do 1280x1024 at 120z.

You probably have a 2560x1440 display, which is definitely a very nice amount of real estate for 3 widths at maybe 120 chars per line. No arguments there.

I just like consistency. Enforcing these things with a linter on your projects really helps, especially if it's an open source source project with a lot of contributers.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 03:52 PM
Quote:
Originally Posted by Shoe Lace
90s? I'm not so sure about that. 1080 is the vertical, the full resolution is 1920x1080.
I don't know what year I had it in, but by 1999 for sure, I had a 21" 1600x1200 display. OK, not quite as wide as 1080p but taller and overall very similar real estate. It was a CRT.

Quote:
You probably have a 2560x1440 display, which is definitely a very nice amount of real estate for 3 widths at maybe 120 chars per line. No arguments there.
I have 2 2560x1600 Dell displays.

Quote:
I just like consistency. Enforcing these things with a linter on your projects really helps, especially if it's an open source source project with a lot of contributers.
Consistency is fine. But the 80 character "standard" came from a technological limitation, not some kind of abstract purism. Feel free to adopt a new standard, no reason to stick with one that was pegged to 1980s technology.

This really isn't similar to the argument against indenting. We don't avoid deep indents because it eats up screen space, we do it because it eats up mental space. That's independent of the technology you use to view your code.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 03:54 PM
Two 21" CRT displays and I pretty much needed to be naked with several fans on me not to overheat. Coworkers were not amused.

I have 2 Thunderbolts now. It's pretty sweet.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 03:59 PM
Probably somewhat sad to admit, but I can't get 80 chars on a single line if I am running two emacs buffers. I think each buffer is about 76 chars.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 04:24 PM
Quote:
Originally Posted by suzzer99
Two 21" CRT displays and I pretty much needed to be naked with several fans on me not to overheat. Coworkers were not amused.

I have 2 Thunderbolts now. It's pretty sweet.
2x CRTs, damn. Your desk must have had structural integrity that rivaled the great pyramids to support that much weight.

Mine was like 60 pounds for 1.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 04:40 PM
Quote:
Originally Posted by daveT
Probably somewhat sad to admit, but I can't get 80 chars on a single line if I am running two emacs buffers. I think each buffer is about 76 chars.
Huge font or small monitor? I can fit about 4.5 and that's including all the cruft emacs adds for scrollbars and stuff.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 06:16 PM
emacs has cruft?



I do all my programming on a laptop. I think it is 14 inch, but not sure.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 06:23 PM
There is a 1 character column on the left and right hand of the screen - I don't actually know what that's "for". If the text wraps the right one will have an indicator but that's a pretty terrible space optimization imo. I have no idea what the left one does. I don't have line numbering on which it looks like you do.

ATM I'm on a windows computer and the windows version of emacs adds a scrollbar to each window, even though really you can only use one at a time. It's probably at least 2 characters wide.

So with 5 panes open, it was "wasting" something like 20 character-widths of screen real estate.

Oh - I see what the left column is for. If your buffer is wider than the window and you scroll right it tells you if there's something on the left. I find both of those columns useless and there's probably a way to remove them.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 06:23 PM
Do you program for a living? I'd be in serious kill-myself territory if I had to use a laptop screen full time.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 06:32 PM
How long have you been using emacs?

Windows init files work fine for the most part and you can remove anything from emacs. I don't have a scroll left / right function. That is just the scratch buffer opened on two panes via C-x 3.

The function to remove the scroll bar is:

Code:
(scroll-bar-mode 0)
All of this works on Windows last I tried it:

http://emacs-doctor.com/emacs-strip-tease.html
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
02-16-2016 , 06:40 PM
Quote:
Originally Posted by daveT
How long have you been using emacs?
Probably about 22 years

Quote:
Windows init files work fine for the most part and you can remove anything from emacs. I don't have a scroll left / right function. That is just the scratch buffer opened on two panes via C-x 3.
Yeah, I know. What I was getting at is this is my game computer - I don't really have emacs "set up", it's just here for when I need to write a little text every now and then.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote

      
m