Go Down

Topic: Significance of color of text in a sketch (Read 788 times) previous topic - next topic


I've been unable to find documentation of the color of text in a sketch. Brown looks like reserved words, blue is text, etc. Here are my questions about the two code fragments. Why are LiquidCrystal.h and Wire.h brown and the other two includes black? Why is minute brown, while hour and second are black. This last one seems to be giving me a problem.

My RTC is on battery but minute gives a new value when the Arduino board is powered up.

#include <LiquidCrystal.h>
#include <DS1307RTC.h>  // a basic DS1307 library that returns time as a time_t
#include <Time.h> 
#include <Wire.h

lcd.setCursor(0, 1);
lcd.print(" ");
lcd.print(" ");
lcd.print("  ");


There is no real significance to the color. What color to assign to certain words is defined in files delivered with libraries, called keywords.txt.

The problem is that every keywords.txt file on your system is read, whether you are using the library that the file comes with, or not.

The presence of a keywords.txt file with a library is not mandatory, so the usefullness of the color coding is just about zip, none, nada, zilch.
The art of getting good answers lies in asking good questions.

Go Up