3 CodingStyle - standards while programming for LilyPond
7 Please use these standards while doing programming for LilyPond
9 Functions and methods do not return errorcodes, but use assert for
17 (add-hook 'c-mode-hook
18 '(lambda ()(setq c-basic-offset 4)))
21 (add-hook 'c++-mode-hook
22 '(lambda() (c-set-style "Stroustrup")
27 =head2 CLASSES and TYPES:
30 AClass_name (for Abbreviation_class_name)
37 the C<type> is a Hungarian notation postfix
41 The source is commented in the DOC++ style. Check out doc++ at
42 F<http://www.ZIB-Berlin.DE/VisPar/doc++/doc++.html>
64 Unfortunately most of the code isn't really documented that good.
68 A lot of classes in LilyPond start with 'P', this is to distinguish
69 certain parts of LilyPond: the P stands for Printer, and the P-classes
70 are supposed to be more lowlevel than the others. Example:
72 Staff uses PStaff, PScore and PCol to do the typesetting of
73 symbols. Staff is the "brains" for PStaff
75 NB: in PCursor (which is part of the library) P stands for PointerCursor
82 ///check that *this satisfies its invariants, abort if not.
85 /// print *this (and substructures) to debugging log
88 /// add some data to *this;
91 Presence of these methods usually imply that it is not feasible to this
95 /// replace some data of *this