Skip to content

Commit d9b5783

Browse files
committed
Sync SDL3 wiki -> header
[ci skip]
1 parent 07af4b2 commit d9b5783

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

docs/README-documentation-rules.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -446,3 +446,19 @@ Beyond stripping the initial ` * ` portion off each line, these comments are
446446
treated as pure Markdown. They don't support any Doxygen tags like `\sa` or
447447
`\since`.
448448

449+
## Enum/struct versioning
450+
451+
If you have an enum or struct, it'll list its `\since` field as the first SDL
452+
release it was available in. However, we might later add new values to an enum
453+
or fields to a struct. These lines, arriving in a newer version, should have a
454+
note about that, like this one on SDL_SCALEMODE_PIXELART:
455+
456+
```c
457+
typedef enum SDL_ScaleMode
458+
{
459+
SDL_SCALEMODE_INVALID = -1,
460+
SDL_SCALEMODE_NEAREST, /**< nearest pixel sampling */
461+
SDL_SCALEMODE_LINEAR, /**< linear filtering */
462+
SDL_SCALEMODE_PIXELART /**< nearest pixel sampling with improved scaling for pixel art (since SDL 3.3.0) */
463+
} SDL_ScaleMode;
464+
```

0 commit comments

Comments
 (0)