How to get the rotation value of a UI Element in WPF -


i've figured out how assign rotation value (element.rendertransform = new rotatetransform(x)), how rotation value of element?

for example, if wanted make 1 ui element have same rotation angle ui element, how that?

you can rotation value doing:

rotatetransform rotation = element.rendertransform rotatetransform; if (rotation != null) // make sure transform rotatetransform {     double rotationindegrees = rotation.angle;     // rotationindegrees here, if needed... } 

if want make uielement rotate in same way, can assign same transform:

element2.rendertransform = element.rendertransform; 

Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -