3 CodingStyle - standards while programming for LilyPond
7 Please use these standards while doing programming for LilyPond
11 Functions and methods do not return errorcodes, but use assert for
19 (add-hook 'c-mode-hook
20 '(lambda ()(setq c-basic-offset 4)))
23 (add-hook 'c++-mode-hook
24 '(lambda() (c-set-style "Stroustrup")
29 =head2 CLASSES and TYPES:
32 AClass_name (for Abbreviation_class_name)
38 if the member's name resembles its type, then I use
66 Unfortunately most of the code isn't really documented that good.
70 A lot of classes in LilyPond start with 'P', this is to distinguish
71 certain parts of LilyPond: the P stands for Printer, and the P-classes
72 are supposed to be more lowlevel than the others. Example:
74 Staff uses PStaff, PScore and PCol to do the typesetting of
75 symbols. Staff is the "brains" for PStaff
77 NB: in PCursor (which is part of the library) P stands for PointerCursor
84 ///check that *this satisfies its invariants, abort if not.
87 /// print *this (and substructures) to debugging log
90 /// add some data to *this;
93 Presence of these methods usually imply that it is not feasible to this
97 /// replace some data of *this