Commit graph

29 commits

Author SHA1 Message Date
Andrea Blankenstijn bac66748ec Merge branch 'wip' 2021-12-23 13:56:08 +01:00
Andrea Blankenstijn a54dc9c2b2 some comment edits, readme draft 2021-08-27 16:08:14 +02:00
Andrea Blankenstijn a19d2ea6bd - mark as const every single read only variable.
- mark as const every pointer that can be const.
- in implementation mark const args passed by value that are meant to be read-only.
- wrap in a lambda complex initializations of (const) values.
- argument passing:
  - pass by value arguments of cheap-to-copy types or meant to be copied
    anyway.
  - pass by (const) reference args not meant to outlive called
    function scope and not cheap-to-copy.
  - pass (const) pointers to (const) args when null is a valid option
    and pointed data aren't expected to outlive function scope.
  - use string_view for non-owned strings (not meant to outlive function
    scope).
  - use span for collection types like vector and arrays.
  - fancy pointers passing:
    - pass by value if a reference will be held:
    - pass by const reference if a reference _may_ be hell.
    - when no references are meant to be held:
        - dereference the pointer to pass the pointed data by reference
          if null is not an option.
        - pass the underlying raw pointer if null is an option.
… and random subtle changes and fixes here and there that I forgot to mention.
2021-08-22 00:57:55 +02:00
Andrea Blankenstijn 76d319fb69 trash commit, style, small api changes (ref vs ptr) and who knows 2021-08-19 15:00:44 +02:00
Andrea Blankenstijn eb777db6dd layout interface-api separation 2021-08-17 12:10:41 +02:00
Andrea Blankenstijn fbaabd5aa7 button interface-api separation 2021-08-17 12:08:38 +02:00
Andrea Blankenstijn 0eb300ceeb caption interface-api separation 2021-08-17 11:39:07 +02:00
Andrea Blankenstijn d9eccc940a rewrite how events are held 2021-08-16 23:13:59 +02:00
Andrea Blankenstijn 6ba5d7fc1c enable widget debug outline when BWIDGETS_DEBUG is defined 2021-08-14 12:06:21 +02:00
Andrea Blankenstijn 280575a0e2 make aligned layout orientation a template parameter. 2021-08-14 11:48:24 +02:00
Andrea Blankenstijn 79f83abe3b smart ptr and a bit of doc 2021-08-10 23:48:19 +02:00
Andrea Blankenstijn 4f82826bbc constness 2021-08-08 14:30:56 +02:00
Andrea Blankenstijn cab6fa0cf4 wip general code improvement 2021-08-07 20:11:28 +02:00
Andrea Blankenstijn 55fbd59c36 half workaround to fix corner glitch in draw_rect and minor changes 2021-07-26 23:48:04 +02:00
Andrea Blankenstijn 30c4205dab some fixes and working sdl wrapper 2021-07-19 23:50:50 +02:00
Andrea Blankenstijn dd3ff9358a big hierarchy refactor, some little changes, add Font class 2021-07-18 18:26:12 +02:00
Andrea Blankenstijn 98f51426b8 basic sdl wrapper 2021-07-16 17:18:13 +02:00
Andrea Blankenstijn 938bb8396c somewhat working code 2021-07-11 17:07:50 +02:00
Andrea Blankenstijn deb11ed9fd wip big rewrite 2021-07-10 19:55:53 +02:00
Andrea Blankenstijn 5a427ec4c2 change file hierarchy 2021-07-09 13:50:17 +02:00
Andrea Blankenstijn 596c506307 add function to get font file through fontconfig 2021-07-08 19:04:16 +02:00
Andrea Blankenstijn dccf6ec7c4 add sf rendered circle rendering feature with basic aa 2021-07-01 14:43:48 +02:00
Andrea Blankenstijn 885ec1a10b make it usable as a meson submodule 2021-06-24 15:09:29 +02:00
Andrea Blankenstijn 3d21921c4a fix Button, working numeric input, build static lib and examples. 2021-06-23 15:39:36 +02:00
Andrea Blankenstijn 4f9ecfcc31 wip caption widget. 2021-06-12 02:16:07 +02:00
Andrea Blankenstijn b21f30cf42 WIP (numeric) Input widget. 2021-06-11 13:30:33 +02:00
Andrea Blankenstijn 51fa4f53a3 Horizontal and vertical layouts. 2021-06-08 14:53:28 +02:00
Andrea Blankenstijn bd5c62c831 wip button widget 2021-06-04 15:43:46 +02:00
Andrea Blankenstijn 2cd5a8e619 initial work 2021-06-03 19:14:02 +02:00