Commit Graph

54 Commits

Author SHA1 Message Date
f6fc2f4a08 Core: Remove skip_cr argument from String 2025-09-28 10:07:24 -05:00
4c4d8b39f1 Clarify truncation behavior in file open modes 2025-08-15 23:53:45 +08:00
ef43409b2f Specified return value in several store methods in FileAccess
Some of the store methods did not specify the nature of return bool value.
Added it after referring to FileAccess.cpp method.

Moved return statement to preceding paragraph

Addressed comments: Moved return description to first line
2025-06-28 10:46:22 +05:30
0b8360ff42 Document the FileAccess read/write cursor
Co-authored-by: Micky <micheledevita2@gmail.com>
2025-06-06 15:44:19 -07:00
13f642d959 Replace XML codeblock spaces with tabs 2025-06-06 14:35:38 +02:00
c24bfb0491 Add missing description of FileAccess.store_half behavior on error 2025-05-08 12:53:52 +08:00
9b3e445e47 Merge pull request #105073 from Mickeon/documentation-miscellaneous-oddities-part-4
Fix miscellaneous oddities around the class reference (part 4)
2025-04-11 09:51:11 -05:00
e935fb1ee2 Fix miscellaneous oddities around the class reference (part 4) 2025-04-10 17:56:58 +02:00
bd98aad3fa Remove misleading and incorrect notes about endianness. Fix FileAccess and StreamPeer not doing what name suggests. 2025-04-09 11:01:25 +03:00
85d3be8070 [FileAccess] Implement get_size and get_access_time methods. 2025-03-09 16:07:00 +02:00
e6e108d091 Implement get_length() for pipes. 2025-02-03 16:50:00 +02:00
156bc92282 Merge pull request #98397 from adamscott/add-tmp-support
Add temp utilities (alias `OS::get_temp_dir()`, `FileAccess::create_temp()`, and `DirAccess::create_temp()`)
2024-12-03 14:40:59 -06:00
1b3e483899 Add file and dir temporary utilities
Co-authored by @Alex2782 for the Android bindings.
Many thanks to the reviewers also.

Co-authored-by: Alex <alex.hart.278@gmail.com>
2024-12-02 12:08:14 -05:00
a4b17e7852 [FileAccess] Return error codes from store_* methods. 2024-11-29 23:22:31 +02:00
c35e4c41d2 Merge pull request #97716 from pafuent/add_half_precision_floating_point_to_stream_peer
Add half precision floating point support to `StreamPeer` and `FileAccess`
2024-11-22 14:54:19 -06:00
086d1ea2ac Update FileAccess.xml 2024-11-19 03:45:03 -05:00
45593d45b3 Allow setting custom initialization vector for FileAccessEncrypted. Add export setting to set static seed for PCK encryption initialization vectors. 2024-11-13 08:16:12 +02:00
eb86670f94 Add half precision floating point support to StreamPeer
Closes godotengine/godot-proposals#5983

Adds put/get methods to `StreamPeer` that handles half precision
floating point values.
Adds endode/decode half precision floating point to `marshalls`.
Adds `get_half` and `store_half` to `FileAccess`

Co-Authored-By: "Alfonso J. Ramos" <theraot@gmail.com>
2024-11-12 08:46:52 -03:00
a07fea1e93 Merge pull request #97906 from Calinou/doc-fileaccess-non-resource-export
Document non-resource file handling in FileAccess and ResourceLoader
2024-11-11 14:18:39 -06:00
e7e0e65159 Fix wording in description of store_line and store_string 2024-10-16 23:41:50 +08:00
f8cc67e175 Document non-resource file handling in FileAccess and ResourceLoader 2024-10-07 01:53:49 +02:00
9315583af3 Fix mismatched parentheses in class reference 2024-05-30 15:54:53 +08:00
40651eb642 FileAccess.xml had conflicting function names in its example code
In the example code the declared load() function conflicts with global scope load(). so if you copy pasted it in godot 4.2.2 you would get a "Too few arguments for "load()" call. Expected at least 1 but received 0." error since it doesn't override global scope load().
2024-04-25 18:51:37 -04:00
504d01b61e Merge pull request #90403 from bruvzg/file_resize
[FileAccess] Implement `resize` method.
2024-04-22 12:51:55 +02:00
b804193f08 [Doc] Clarify behavior of FileAccess.get_line
Specifies that the line excludes any newline or carriage return
characters.
2024-04-16 19:22:40 +02:00
88b3e68f93 [FileAccess] Implement resize method. 2024-04-12 19:20:49 +03:00
328b00774b Use [codeblock lang=text] more often in class ref 2024-04-08 16:17:50 +02:00
c83718624f Update links to outdated asset library demos
Update links to outdated asset library demos

Co-authored-by: Max Hilbrunner <m.hilbrunner@gmail.com>
2024-04-07 16:59:43 +02:00
24c9d442e9 [Doc] Fix some incorrect uses of a/an 2024-03-13 21:20:28 +01:00
a775d8bf5a Clarify behavior of opening a new file in FileAccess
The containing directory must exist for this to succeed.
2024-03-05 19:34:19 +01:00
e5270c0db2 Link to runtime loading/saving tutorial and improve Image documentation 2023-11-14 12:05:54 +01:00
bf3f6e3b55 Error handling for FileAccess.get_file_as_*
- Assign last error in said `FileAccess.get_file_as_bytes` and `FileAccess.get_file_as_string`
- Document error handling for said methods
2023-10-11 18:52:16 +02:00
cc0eebd9d8 Validate code tags for class and member references
This commit also adds means to manually disable warnings
in `code` tags where it's a false positive with the new
`skip-lint` attribute.

Warnings are now enabled on CI to prevent future errors.
2023-10-03 15:48:31 +02:00
d026b37abd Fix various typos in classref 2023-08-22 18:05:50 +08:00
8aa6f29b56 [FileAccess] Add methods to get/set "hidden" and "read-only" attributes on macOS/BSD and Windows. 2023-08-08 21:51:32 +03:00
81064cc239 Doctool: Remove version attribute from XML header
We don't use that info for anything, and it generates unnecessary diffs
every time we bump the minor version (and CI failures if we forget to
sync some files from opt-in modules (mono, text_server_fb).
2023-07-06 10:08:21 +02:00
346f1ab86b Bump version to 4.2-dev
Keep on waitin'
2023-07-05 22:07:03 +02:00
aaf43a260e Docs: Add FileAccess.close, remove dupl. example 2023-05-31 16:28:21 +02:00
04562662d3 Overhaul the top sections of the class reference (Core classes) 2023-05-19 07:04:48 +02:00
6bccdec7a1 Make documentation sorting use natural order 2023-05-09 17:47:52 +02:00
391eccca76 Validate code tags in documentation for potential params
Adds a check to make_rst to look for matches
between the text inside of the [code][/code] tag
and known param identifiers.
Fixes most of what was revealed.
2023-04-26 21:36:04 +02:00
0e4bd964cc Expose brotli decompression to the scripting API. 2023-03-29 22:43:36 +03:00
1c1524a651 Bump version to 4.1-dev
Can't stop, won't stop, they said, huh?
2023-03-01 01:44:37 +01:00
0c92c92891 Various classref typo fixes 2023-02-20 14:47:37 +08:00
bc95b0b171 Restore FileAccess.close method. 2023-02-16 15:34:20 +02:00
5ca1123021 Merge pull request #71572 from RedMser/docs-binary-variant
Document internal usage of `encode`/`decode_variant`
2023-02-10 20:04:16 +03:00
7eb8325180 Fix C# examples in documentation
- Fix documentation after C# renames.
- Add missing `partial` in C# class declarations.
- Change `delta` parameter type to `double` in C#.
- Ensure parameters match base declaration.
- Use `$` string interpolation in C#.
- Fix invalid or outdated C# code.
- Changed some examples to follow our style guide more closely.
2023-01-31 19:04:07 +01:00
dc70ab5e2d Document internal usage of encode/decode_variant 2023-01-17 18:42:26 +01:00
ecec415988 Use system fonts as fallback and improve system font handling.
Add support for font weight and stretch selection when using system fonts.
Add function to get system fallback font from a font name, style, text, and language code.
Implement system font support for Android.
Use system fonts as a last resort fallback.
2022-12-04 18:44:20 +02:00
Emi
d196a07ea4 Replacing File calls from the FileAccess class docs
Co-Authored-By: bruvzg <7645683+bruvzg@users.noreply.github.com>
2022-10-03 13:04:40 +02:00