-
Notifications
You must be signed in to change notification settings - Fork 672
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
Fixes #2114. 3D Effect #3376
base: v2_develop
Are you sure you want to change the base?
Fixes #2114. 3D Effect #3376
Conversation
This illustrates an issue with my current design here: Need to figure out how to have the shadow account for whatever was drawn below. Right now, it blindly overwrites and thus doesn't look right in some situations. I think the right design is to have Margin.Draw get called by Application, not the View's SuperView. |
Fixes gui-cs#3503. Improves "View Editing" for Scenarios (e.g. `AdornmentsEditor`)
Broke some stuff.
That's kinda been a long-standing conundrum, hasn't it? What order to draw things in, I mean. Since we don't have an explicit concept of Z index, it's all just order dependent, which is something that can change at runtime as views are created and destroyed. As far as what color to use, I've got blend code that's aimed at true color but works for lame color too. I may have even put at least some of it in when I did that work on the Color type a while back. 🤔 |
Fixes gui-cs#3497. Removes `LayoutStyle`
Fixes gui-cs#3501. `ContentSize` -> `GetContentSize()`/`SetContentSize()`
…iewport Fixes gui-cs#3140. TextView assumes Frame == Bounds
@@ -198,6 +198,9 @@ public LineStyle LineStyle | |||
|
|||
private bool _showTitle = true; | |||
|
|||
/// <summary> | |||
/// Gets or sets whether the title should be shown. The default is <see langword="true"/>. | |||
/// </summary> | |||
public bool ShowTitle |
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.
I just had a thought about this (in general - not just for this property on this class) that I want to test out at some point.
Since we do not have constructors and are thus using a property-based dependency model, I wonder how these might behave if set to a different value in an initializer, especially if other properties any property setter depends on may have already been set. 🤔
My thinking is that it's a potential for strange NullReferenceExceptions and potential slow resource leakage due to event subscriptions from objects whose references haven't even been pushed onto the evaluation stack yet.
Purely theoretical but making the note both for myself and in case anyone already has specific insight on that behavior in the CLR.
Fixes
Button
and other views #2144Todo
Margin
to have a "Shadow" Style - When enabled draws the correct half-height block glyphs in the right placesButton
to useMargin.EnableShadow
Button
with shadow work reliably and automatically.Margin.Draw
get called byApplication
, not the View's SuperView.EnableShadow
on other Views where it may make sense visually.Background
When I created Frames (now Adornments) i had a vision that
Margin
could be used to enable the 3D effect that we had mostly working in v1, but got negated with all the changes to v2.I had a shower thought recently on this and decided to quickly code a prototype up to see if my instincts were right.
This PR demonstrates that I was. The concept is leveraging Margin like this:
Pull Request checklist:
CTRL-K-D
to automatically reformat your files before committing.dotnet test
before commit///
style comments)