Questions tagged [visualbrush]

84 questions
1
vote
2 answers

RenderTransform in WPF causing unexpected layout changes

I am trying to animate a number of shapes within a visualbrush but when I perform a rotation the shapes 'pulse'. I am assuming that as the shapes rotate the bounding boxes are forcing a layout pass. However since I am using a RenderTransform I…
DocGigawatts
  • 285
  • 6
  • 15
1
vote
0 answers

Is it possible 3D brush react native / drawing using AR

I'm planning a new project and we decided to use react native and expo. But we have that one requirement that is: The user can draw 3D in real life using camera. Would it be possible for us to pull this off? Or we should change react native? If you…
1
vote
1 answer

WPF - clone contents of container as geometry

Ok ive had a lot of bad luck using a visualbrush to try to print out pages from subsections of a large canvas. Works in general, but tends to rasterize some parts and creates bad output. (I've asked questions about this before). So now I'm creating…
Brady Moritz
  • 8,624
  • 8
  • 66
  • 100
1
vote
3 answers

WPF - Border with a OpacityMask/VisualBrush: Memory Leaks

A brief explanation about my app: the application in which I'm working on is such a greeting cards designer. Imagine something in which there is a background image, and an indefinite number of "layers" (in particular, pictures) that stay over the…
superpole
  • 11
  • 3
1
vote
0 answers

Listbox control template object is ignoring size properties

I am pretty much a beginner in WPF C# programming, so sorry for stupid question's. DESCRIPTION: In the ListBox I have defined the ControlTemplate. Inside of it is located also the "PieDiagram" object. The "PieDiagram" object have an property "Size"…
Pukaai
  • 367
  • 1
  • 4
  • 14
1
vote
0 answers

How to make VisualBrush-icons in WPF stretch the same way

What's already working: I want to use SVG-icons in my applications. So I have downloaded a few icons from Material.io and converted them with Inkscape into XAML files. The content of these files is then used in a as a…
drvolcano
  • 110
  • 9
1
vote
2 answers

Rotated Element creates issues with adorner

I have a problem with my adorner which is supposed to preview the destination of my drag & drop operation, everything is working fine until i rotate the adorned element. My adorner is a rectangle which is filled with a visual brush of the adorned…
raphi011
  • 502
  • 1
  • 6
  • 23
1
vote
1 answer

Set Binding over App.xaml programmatically

I want to use a VisualBrush in App.xaml: Then I want to set a binding in one window like this: VisualBrush testBrush =…
Marcel Grüger
  • 885
  • 1
  • 9
  • 25
1
vote
1 answer

WPF - XAML - Call an animation in a nested style from the parent style

I'm trying to modify an ItemsControl to have a watermark to indicate the behavior of content dropped into it. I'm using a Label inside a VisualBrush to show the word "OR" as the background to the ItemsControl (The control will contain property…
Ian Carson
  • 139
  • 1
  • 10
1
vote
2 answers

Scale a Visual Brush Background WPF

I have a Item called MiniMap in my xaml. I have set the background of it to a visual brush representting a canvas Item. Now, I want to scale the background to a ratio 0.7 . How can I do it? Thanks in advance
user279244
  • 961
  • 5
  • 18
  • 32
1
vote
2 answers

Creating a VisualBrush without ever displaying the Visual it represents

Using the code below, I am attempting to fill a Canvas with UIElements and save it as a tif Image. However, my Image is always blank. It is because the Canvas is never displayed on the screen and some sort of initialization and drawing never took…
Dan Vogel
  • 3,858
  • 7
  • 41
  • 57
1
vote
0 answers

WPF Visualbrush to Imagesource

I would like to save a VisualBrush to a file. I've tried many different solutions but nothing worked. I've tried to write a simple Converter: public class BrushToImageSourceConverter : IValueConverter { public object Convert(object value, Type…
Florian
  • 5,918
  • 3
  • 47
  • 86
1
vote
1 answer

Why is the fill of an Ellipse not applied when the Stretch property is set inside a VisualBrush?

I'm working on a custom control and I have a VisualBrush with the Visual property as such:
Ashley Grenon
  • 9,305
  • 4
  • 41
  • 54
1
vote
0 answers

Binding a Label in a TileBrush?

I am working on a Timeline control, so far I have: I need to get the '00:00' markers bound to what their actual value should be. The first one, which is shown in the picture, should be '00:01' next Blue line should be '00:02' I know my design…
jpiccolo
  • 768
  • 1
  • 6
  • 19
1
vote
1 answer

VisualBrush of a Window in another Window

So basically, the MainWindow opens a second Window, let's say OptionsWindow. So in the OptionsWindow I want to show a visual of the MainWindow. I tried this, but didn't work:
Carlo
  • 25,602
  • 32
  • 128
  • 176