-
i am trying to draw some text with effect like this: I remember there was a documentation page for it and it had an image with purple text. But now I can't find that page. |
Beta Was this translation helpful? Give feedback.
Answered by
castorix
Jan 1, 2024
Replies: 2 comments 6 replies
-
A simple way is to use a TextBlock |
Beta Was this translation helpful? Give feedback.
3 replies
-
Same code with TranslateTransform/RotateTransform (test with GDI+ in WM_PAINT) for a rotated text as watermark : |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It is quick draft code atm but it is about the same as the code from Junjie Zhu - MSFT in your thread in MSDN (https://learn.microsoft.com/en-us/answers/questions/1465983/how-to-port-drawingbrush-stuff-from-wpf-to-winui-3)
The only difference is that I draw it in WM_PAINT (SetWindowSubclass, ...) and I added a SwapChainPanel (like in the GitHub sample for transparency) to show the background
But it could be simpler with Composition (although I had tried without Win2D (like in Wice) and failed...)