c# - WPF - Resizing chromeless windows using attached behaviors,..Any suggestions? -
c# - WPF - Resizing chromeless windows using attached behaviors,..Any suggestions? -
who fancies challenge?
i'm working on controltemplate chromeless window part of reusable theme assembly. want behaviors moving, closing, minimizing , restoring implicit i've written attached behaviors functionality i've included in template.
now,..i've come resizing , i've come junction. improve or worse i'm handling mouse move in behavior , finding whether cursor within resizing 'zones'. i'm far plenty alter cursor appropriately i've gotten resizing window there 3 options i've come across.
i hand-ball affair , adjust left & top , width & height needed. simplest alternative , achievable using attached behaviors seems moderately heavy lifting , understand wpf go on render window adjusted causing flickering,..which sucks.
the sec alternative message hook , hear wm_nchittest , solutions i've found far involve me sub-classing window , don't want forcefulness consumers of theme utilize controls aren't framework provided.
the lastly alternative somehow draw rectangle on screen showing window take mouse dragged , resize on mouseup,..which seems doable it's not i've done before pointers on cool.
so,..what should do? win32 route seems best alternative far i'd rather not if has 'purer' solution works. i'm happy suggestions alternative 3 , right .net 4 in case dynamic magic might possible.
thanks in advance.
c# wpf interop resize attachedbehaviors
Comments
Post a Comment