Pages: [1]   Go Down
Author Topic: Line numbers  (Read 2109 times)
0 Members and 1 Guest are viewing this topic.
Phoenix, AZ
Offline Offline
Jr. Member
**
Karma: 1
Posts: 90
Retired engineer still playing with gadgets.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

How do I get the line numbers to show up in a sketch? It would be really be helpful in debugging. Also, when starting a new topic, how do I cut and paste the errors. Currently, after highlighting, a right click does nothing.
Thanks for the help.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 9
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello,

I was recently in search of line numbers, as well, but it doesn't appear to be a feature of the IDE.

http://forum.arduino.cc/index.php?topic=46947.0

Logged

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

https://github.com/arduino/Arduino/issues/1502

https://github.com/arduino/Arduino/issues/976

https://github.com/arduino/Arduino/issues/227

You could always try to prod the developers along with a comment on one of those feature requests.
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2187
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Your line number is there in the bottom left corner of the Arduino IDE screen

You may want to have a look at the free NotePad++ program (it has line #s and much much much more) use it for writing your sketches. Also has a nice Conversion panel to aid in programming. Saves in Rich Text format etc.
You can set the Arduino IDE to use an external editor in Preferences.
When you compile the sketch it reloads the file that you are editing in NotePad++ (of course save the sketch prior to compiling).

http://notepad-plus-plus.org/

EDIT:  This will make NotePad++ more  comfortable with Arduino sketches.
Follow the steps in  Post #1                  http://forum.arduino.cc/index.php?topic=141050.0
« Last Edit: August 05, 2013, 07:50:27 pm by LarryD » Logged

Poole, Dorset, UK
Offline Offline
Edison Member
*
Karma: 25
Posts: 1883
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Highlight, control-c (to copy), control-v (to paste), control-x (to delete).

Mark
Logged

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8458
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Line numbers have been asked for a gazillion times, it will never happen.

Notepad++ is one of the best editors around, also you could start using Atmel Studio or maybe the Uecide IDE, that seems to be coming along nicely.

_____
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

Phoenix, AZ
Offline Offline
Jr. Member
**
Karma: 1
Posts: 90
Retired engineer still playing with gadgets.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks to all. I never notices those little numbers in the lower left corner before. They're pretty subtle. I'll check out notepad. Also, I forgot about using control c to copy.
Thanks again.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Line numbers have been asked for a gazillion times, it will never happen.

Notepad++ is one of the best editors around, also you could start using Atmel Studio or maybe the Uecide IDE, that seems to be coming along nicely.

_____
Rob

Why, it will never happen ?
It's something that seems not to be so hard and surely would be very helpful.
And if that is so asked, why not do that?   
Logged

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8458
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I say that because it's been asked a 1000 times and so far has not happened and I'm extrapolating into the future smiley

Quote
It's something that seems not to be so hard and surely would be very helpful.
Correct on the second point and I assume also the first although I don't know how the IDE has been coded.

It's a very useful feature but either there's nobody that can/will do it or people are happy with a single number at the bottom. 

Maybe those that care use a decent editor anyway and don't push for change, like me.

I don't know but I wouldn't hold your breath.

_____
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

Lake Tyers Beach
Offline Offline
Full Member
***
Karma: 1
Posts: 101
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Folks,

I am using 1.5.1r2 and was also wondering about IDE line numbers, but I found that I could not see the line number reference in the bottom LHS status line (mentioned above) until I had done a "restore down" on the IDE and re-juggled the IDE's window bits'n'bobs with a "maximise" and then the status line came into view.  I may have been using a "window reference" from an IDE long ago that did not show this extra bit. Try it, that is all it may require.

Anyway, I am happy (for the moment  smiley )

Rob
Logged

Learning Flute and C++, heading for a meltdown.

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8458
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Anyway, I am happy (for the moment  smiley )
Then you are easily pleased smiley

_____
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

France S-O ou exil en IDF
Offline Offline
Edison Member
*
Karma: 25
Posts: 1904
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

There is no line numbers because the Arduino IDE is actually  "IDE Processing" and there is no line numbers in Processing.
If the Arduino team has not added line numbers it is because they do not know how to make it.
To have line numbers you have to  ask the Processing team.

Don't foget the chain :  Processing -> Wiring project  ->  Arduino project = fork of Wiring project

The only solution is to use an external editor or uecide or eclipse or code::blocks.
The uecide author has rewrite the editor and some other features like the serial-monitor.
« Last Edit: September 28, 2013, 04:58:49 am by 68tjs » Logged

Pages: [1]   Go Up
Jump to: