# Paint Context is moving further than the Widget that contains it (more info below).

**URL:** <https://forums.unrealengine.com/t/paint-context-is-moving-further-than-the-widget-that-contains-it-more-info-below/491222>\
**Category:** UI\
**Tags:** draw, paint, unreal-engine, Widget, question\
**Created:** [November 23, 2021, 9:09am UTC](https://forums.unrealengine.com/t/paint-context-is-moving-further-than-the-widget-that-contains-it-more-info-below/491222 "2021-11-23T09:09:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChachoVoyColacao](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ChachoVoyColacao](https://forums.unrealengine.com/u/ChachoVoyColacao)\
**Post date:** [November 23, 2021, 9:09am UTC](https://forums.unrealengine.com/t/paint-context-is-moving-further-than-the-widget-that-contains-it-more-info-below/491222/1 "2021-11-23T09:09:47Z")

</div>

I’m overriding Widget’s OnPaint function to draw lines. It works great at first, but if I place my child widgets (the one who does the override) in a different place of their parent Canvas, the PaintContext moves to a wrong position (or something like that). Any idea on how to fix this behavior?

 ![352875-image-2021-11-23-100647.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/5/f/35f15423e27b28bf78a250ae6e4235f8ef02059f.png)
