-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Merged by Bors] - Add documentation to the WindowDescriptor struct. #4764
Conversation
01342e4
to
f7e494a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are excellent docs. Some small nits, but this is nearly ready.
cb5e626
to
1f10578
Compare
1f10578
to
afdc97f
Compare
@bevyengine/docs-team can I get a second review? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work! Especially the comment on the struct itself will be really beneficial for a lot of users.
Co-Authored-By: Alice Cecile <[email protected]>
afdc97f
to
a1e1770
Compare
Also added a short comment for decorations in the last change as it isn't descriptive at first glance (or at least for me). So I searched it in winit and found that it is responsible for borders and bars. |
Awesome, thanks again! BTW, in the future, prefer many small commits over rebasing when contributing here. We squash on merge, and the separate commits make it easier for reviewers to quickly check what's changed. |
bors r+ |
# Objective Resolves #4753 ## Solution Using rust doc I added documentation to the struct. Decided to not provide an example in the doc comment but instead refer to the example file that shows the usage.
Build failed: |
Ah, #4575 strikes again. Not your fault here. |
Ok, thanks for the guideline :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good improvement. Adding docs is always helpful to readers who want to learn more.
To my eyes this PR only needs some adjustments on what has been already changed. I specified them in the comments below.
Also, I feel that this needs some other additions, in particular to undocumented fields, because #4753 requires that all fields should be documented to be closed.
title
,resizable
,cursor_visible
,cursor_locked
,
have been probably left out because they are trivial, but a well thought short description is always helpful.
The fields:
resize_constraints
present_mode
mode
are even easier to document, since a link to the type with a minimal description is sufficient.
Co-authored-by: Federico Rinaldi <[email protected]>
Co-authored-by: Federico Rinaldi <[email protected]>
… document-window-descriptor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work with documenting all fields!
Once the wording suggestion below is applied, I will feel comfortable to approve this PR. 😄
Co-authored-by: Federico Rinaldi <[email protected]>
I don't understand why it fails. Do I need to do something else? |
Not your fault; this was a flaky check that we've since removed. |
bors r+ |
# Objective Resolves #4753 ## Solution Using rust doc I added documentation to the struct. Decided to not provide an example in the doc comment but instead refer to the example file that shows the usage.
# Objective Resolves bevyengine#4753 ## Solution Using rust doc I added documentation to the struct. Decided to not provide an example in the doc comment but instead refer to the example file that shows the usage.
# Objective Resolves bevyengine#4753 ## Solution Using rust doc I added documentation to the struct. Decided to not provide an example in the doc comment but instead refer to the example file that shows the usage.
Objective
Resolves #4753
Solution
Using rust doc I added documentation to the struct. Decided to not provide an example in the doc comment but instead refer to the example file that shows the usage.