2092Fermer2094
FarewellLe 08/11/2016 à 20:12
tu peux ajouter des consignes avec clang-format cheeky

Pen² -> je ne code pas comme un porc, mais si tu regardes la doc, tu vois qu'il y a plein de trucs commodes, comme l'alignement des commentaires situés sur plusieurs lignes, des affectations, des labels (très courants en C++ avec les public/protected/private), et autres choses pénibles à reformater quand on change une simple ligne.

(genre ça :
struct gl_widget;
typedef struct gl_widget {
    unsigned short type;      // Internal type
    struct gl_widget* parent; // Parent widget
    short x;                  // Absolute position on the screen. Computed at drawing time (DrawWidget())
    short y;                  //
    short width;              // Dimensions. Computed at preparation time (PrepareWidget())
    short height;             //
    bool dirty;               // True if the dimensions of the widget must be computed before drawing.
    short alignment;          // Graphical aligment in the parent layout
    bool enabled;             // True if the widget is displayed in normal mode and executable
} gl_widget;
Cette structure ne cesse d'évoluer, pourtant les commentaires sont toujours bien positionnés en un clic)