Quantcast
Channel: Visual Studio Integrate forum
Viewing all articles
Browse latest Browse all 4410

How to add adornment relative to the top right corner of viewport?

$
0
0

AdornmentPositioningBehavior.ViewportRelative seems to relative top left corner of viewport, but I wana to set adornment relative to the top right corner of a viewport. I also look into the code of 'Microsoft.VisualStudio.Platform.VSEditor.dll', the implement code seems to only care about Grid.Left and Grid.Top which does not care Grid.Right so when I attach Grid.Right to the custom element does not work.

Are there any other methods or suggestion?

Problem Details:

implement a custom adornment to the textedtior's AdornmentLayer and make its position relative to the top right corner of the viewport. The reason I want to make its position realtive to the top right corner of a viewport is that the element in the adornment has an automatic size. 


msdn 论坛回复


Viewing all articles
Browse latest Browse all 4410

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>