8ae2c9cf5f
FIX: LoadFontDataBDF() #5346
2025-11-12 10:22:56 +01:00
ec06f9be37
Removed trailing spaces
2025-10-21 13:51:03 +02:00
adfe2c1704
C++ compiler support v2 ( #5252 )
...
* Get C++ compilers working
* Fix Formatting
2025-10-15 19:11:44 +02:00
5dd97ecf2f
REVIEWED: TextToPascal(), fix https://github.com/raylibtech/rtools/issues/57
2025-10-07 19:42:05 +02:00
37149082e8
Avoid warnings
2025-09-29 18:05:16 +02:00
23e0898c65
Ouch!
2025-09-18 15:51:18 +02:00
c264c86ee0
ADDED: Some useful functions for Files and Text management
...
// File management functions
- int FileRename(const char *fileName, const char *fileRename); // Rename file (if exists)
- iint FileRemove(const char *fileName); // Remove file (if exists)
- iint FileCopy(const char *srcPath, const char *dstPath); // Copy file from one path to another, dstPath created if it doesn't exist
- iint FileMove(const char *srcPath, const char *dstPath); // Move file from one directory to another, dstPath created if it doesn't exist
- int FileTextReplace(const char *fileName, const char *search, const char *replacement); // Replace text in an existing file
- iint FileTextFindIndex(const char *fileName, const char *search); // Find text in existing file
// Text management functions
- const char *TextRemoveSpaces(const char *text); // Remove text spaces, concat words
- char *GetTextBetween(const char *text, const char *begin, const char *end); // Get text between two strings
- char *TextReplace(const char *text, const char *search, const char *replacement); // Replace text string (WARNING: memory must be freed!)
- char *TextReplaceBetween(const char *text, const char *begin, const char *end, const char *replacement); // Replace text between two specific strings (WARNING: memory must be freed!)
2025-09-18 15:34:09 +02:00
ed8f1a22d1
Remove trailing spaces
2025-09-14 18:07:58 +02:00
8e52aee853
Update rtext.c
2025-09-05 00:13:32 +02:00
51aa8776bb
Update rtext.c
2025-09-04 23:53:26 +02:00
0203a47bf9
REDESIGNED: LoadTextLines()/UnloadTextLines()
2025-09-04 23:25:42 +02:00
2cb387b50a
REVIEWED: Font atlas image generation, added some comments #5141
2025-09-03 18:30:00 +02:00
1fa3c15942
Revert "add const qualifier to the first arg of TextJoin ( #5166 )"
...
This reverts commit 4e8d08523f .
2025-09-02 19:00:22 +02:00
4e8d08523f
add const qualifier to the first arg of TextJoin ( #5166 )
...
* add const qualifier to the first arg of TextJoin
* Update raylib_api.* by CI
* Update raylib.h
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Ray <raysan5@gmail.com >
2025-09-02 18:58:39 +02:00
29ce5d8aa9
WARNING: BREAKING: LoadFontData() redesigned, added parameter
...
This redesign is a big improvement on font loading time and memory requirements. It only loads glyphs available on font from requested codepoints and only processes those glyphs for packaging. When processing +10K codepoints (CJK), the loading time improves considerably.
2025-09-02 17:45:39 +02:00
8f32c502a7
REVIEWED: Code sections definition
2025-09-02 12:10:40 +02:00
1777da9056
REVIEWED: Avoid realloc() calls, small security improvement
2025-09-01 20:37:23 +02:00
0a92c863c4
Reverted const codepoints to avoid warnings
2025-09-01 11:27:11 +02:00
edce3d41b2
REVERT: Making codepoints const, variable is used to generate list in case it was NULL
2025-08-31 12:11:03 +02:00
ecedf40da6
REVIEW: const for codepoints arrays passed to function #5159
2025-08-31 11:39:14 +02:00
d2f6c4924c
ADDED: [rtext] LoadTextLines()/UnloadTextLines()
2025-08-26 10:17:33 +02:00
52980c947d
REVIEWED: [rtext] Provide more detailed info on glyphs failing to pack #5141
2025-08-24 11:07:55 +02:00
3c9c66e72b
use RL_MALLOC in stb_truetype
2025-08-23 13:10:27 +03:00
570082deba
WARNING: **NEW** raylib code CONVENTION: Comments do not end with '.'
2025-08-07 18:23:20 +02:00
7b017b60d9
Move global variable to right code section
2025-07-21 10:57:21 +02:00
3d93b30262
Update font load message
2025-07-18 15:20:38 +02:00
59bcf680aa
Code gardening...
2025-06-07 20:14:24 +02:00
5ddd13b775
REVIEWED: Hexadecimal formatting to be consistent
2025-05-28 17:18:02 +02:00
9d4c31533d
Update rtext.c
2025-05-14 23:47:03 +02:00
ebaa922f6b
Properly clean up the default font on unload, it may be reused if the window is created again
2025-05-08 09:57:31 -07:00
94c5de33a0
Make the default font loadable before InitWindow, for use with the image API.
...
Make the default font loader early out if we have already loaded parts of it, so we don't leak memory
2025-04-30 17:56:30 -07:00
5b940692ea
REVIEWED: ExportFontAsCode() not checking isGpuReady #4894
2025-04-15 13:09:44 +02:00
1d87932d93
TextSubtext fixes ( #4759 )
...
Fix buffer write overflow
Fix reading past the end of text
2025-02-12 23:12:10 +01:00
99dfec070a
[rtext] fix: misuse of cast in GetCodepointCount ( #4741 )
...
I was really wondering what is going on here :D I believe this code
tried initially to out-cast 'const' specifier but this is not needed here
at all. Currently, it just confuses whoever reads this so I changed it.
The old code would also trigger -Wcast-qual warning on some compilers.
2025-01-31 14:44:23 +01:00
e227371265
REVIEWED: TextJoin(), convert const char ** to char**
...
It generates multiple issues: https://c-faq.com/ansi/constmismatch.html
2025-01-11 23:38:21 +01:00
49b905077d
remove trailing spaces
2025-01-11 19:36:26 +01:00
bf8962dbc7
REVIEWED: Remove some const from text buffer return values
...
Lately got some compilation `errors` related, it seems GCC 14 interprets some `const`-missmatch as errors instead of warnings (as previous versions).
But in any case, I don't see why an user won't be able to operate directly over of those returned buffers; `const` adds a restriction (for security reasons?) that in my opinion is useless.
From an expert on compilers (w64devkit creator), here there are some notes I agree with:
```
No const. It serves no practical role in optimization, and I cannot recall an instance where it caught, or would have caught, a mistake. I held out for awhile as prototype documentation, but on reflection I found that good parameter names were sufficient. Dropping const has made me noticeably more productive by reducing cognitive load and eliminating visual clutter. I now believe its inclusion in C was a costly mistake.
(One small exception: I still like it as a hint to place static tables in read-only memory closer to the code. I’ll cast away the const if needed. This is only of minor importance.)
```
Ref: https://nullprogram.com/blog/2023/10/08/
2025-01-10 13:06:28 +01:00
fa0eada61a
Update year to 2025
2025-01-01 00:02:52 +01:00
7868d600f4
[rtext] Fix default font alpha on Big Endian systems ( #4624 )
...
* Fix rtext default font alpha on Big Endian
* Endian Indepence
2024-12-23 22:25:22 +01:00
1f45e7af76
REVIEWED: Coding conventions
2024-12-03 19:14:14 +01:00
962f1c26ff
Review formatting to follow raylib conventions
2024-12-01 23:10:59 +01:00
da6fa1d756
Fix #4529
2024-11-22 11:06:34 +01:00
d15e583460
Update rtext.c
2024-10-29 09:37:38 +01:00
de7ab83f5a
Fix empty input string for MeasureTextEx ( #4448 )
2024-10-29 09:33:03 +01:00
f141c75cde
Removed trailing spaces
2024-10-21 17:00:52 +02:00
8cbf34ddc4
WARNING: BREAKING: Renamed several functions for data validation #3930
2024-10-16 19:26:12 +02:00
735308f8eb
REVIEWED: CodepointToUTF8(), clean static buffer #4379
2024-10-13 20:02:40 +02:00
1eb8ff5e54
LoadFontDefault(): Initialize glyphs and recs to zero #4319
2024-09-22 18:05:58 +02:00
f5ef357810
Update rtext.c
2024-08-25 13:55:53 +02:00
4c9282b090
ADDED: isGpuReady flag, allow font loading with no GPU acceleration
2024-08-24 18:59:24 +02:00