Pages: [1]   Go Down
Author Topic: BBEdit v10 and syntax highlighting  (Read 1659 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi all,

I would like to use BBEdit as a code editor.
However, I cannot find how to add Arduino syntax highlighting and completion (the reason why I wanted to use BBEdit in the first place...)

Has anyone ever pulled that off?

--edit: rephrase
« Last Edit: June 04, 2012, 09:54:21 am by hfp777 » Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 551
Posts: 46214
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
However, I cannot find how to add Processing syntax highlighting and completion
Are you in the habit of asking Arduino questions on the Processing forum, too? What exactly is your Arduino issue?
Logged

Des Moines, WA - USA
Offline Offline
God Member
*****
Karma: 25
Posts: 779
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Depending upon your version of BBEdit the following should be used as a rough guide.

BBEdit->Preferences

Select "Languages" from the list on the left.

Click the '+' under the "Custom Extension Mappings" pane.

Select the "Suffix" side of the new entry and enter extension used by your version the Arduino IDE.

Click on the "Languages" side and select "C++" form the pop-up menu.

You should be good to go!
« Last Edit: June 03, 2012, 10:21:23 pm by lloyddean » Logged

Gosport, UK
Offline Offline
Faraday Member
**
Karma: 19
Posts: 3114
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Isn't Processing Java?
Logged

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
However, I cannot find how to add Processing syntax highlighting and completion
Are you in the habit of asking Arduino questions on the Processing forum, too? What exactly is your Arduino issue?

Processing is the language Arduino is using, is it not?
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Depending upon your version of BBEdit the following should be used as a rough guide.

BBEdit->Preferences

Select "Languages" from the list on the left.

Click the '+' under the "Custom Extension Mappings" pane.

Select the "Suffix" side of the new entry and enter extension used by your version the Arduino IDE.

Click on the "Languages" side and select "C++" form the pop-up menu.

You should be good to go!

Thanks but when doing this, instructions like pinMode, Serial.begin etc are not recognised and highlighted. This is very useful to read the code and this is what I am trying to accomplish in BBEdit.
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Gosport, UK
Offline Offline
Faraday Member
**
Karma: 19
Posts: 3114
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Processing is the language Arduino is using, is it not?

No. The Arduino IDE is based on the Processing IDE. Processing (the language) is Java, the Arduino language is C/C++.
Logged

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Processing is the language Arduino is using, is it not?

No. The Arduino IDE is based on the Processing IDE. Processing (the language) is Java, the Arduino language is C/C++.

My bad. So how to have BBEdit display Arduino's language like in the IDE where functions and libraries are highlighted?
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Austin, TX
Offline Offline
Faraday Member
**
Karma: 64
Posts: 6055
Baldengineer
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

https://github.com/carlynorama/Arduino-BBEdit
Logged

Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


Yes I saw this before but there is no explanation whatsoever regarding how to install it?
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Austin, TX
Offline Offline
Faraday Member
**
Karma: 64
Posts: 6055
Baldengineer
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I guess I would install those files mentioned on page 360 of this document:
http://pine.barebones.com/manual/BBEdit_10_User_Manual.pdf
Logged

Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Copying the .plist files to the directory mentioned in the doc doesn't cut it smiley-sad
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Gosport, UK
Offline Offline
Faraday Member
**
Karma: 19
Posts: 3114
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've just downloaded BBEdit, and the files from github. I created a Macintosh HD/Library/Application Support/BBEdit/Language Modules directory and copied the github files to it. Started BBEdit and opened a .pde file and the highlighting was working. As I use IDE 1.0, I changed the file suffix line to
Code:
        <key>BBLMLanguageSuffix</key>
        <string>.ino</string>
and it now works for ino files instead.
Logged

Offline Offline
Full Member
***
Karma: 0
Posts: 118
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, this method worked. I initially created the directory in my user folder not on the Macintosh HD
Logged

I am a total amateur at electronics and all things related. I have no education in the matter other than self taught.

Please factor this in

Pages: [1]   Go Up
Jump to: