4
A
回答
2
首先要做的就是讓自己的ScrollViewer模板的副本。 Blend使這非常簡單。在VS你有更多的工作要做。讓我們開始基本UserControl
<UserControl ....>
<Grid x:Name="LayoutRoot">
<ScrollViewer ...>
<!-- Content here -->
</ScrollViewer>
</Grid>
</UserControl>
得到的文檔ScrollViewer Styles and Templates,你會發現這裏這種控制現有的XAML。將其複製並放入UserControl
資源中。
<UserControl ....>
<UserControl.Resources>
<Style x:Key="MyScrollViewerStyle" TargetType="ScrollViewer">
<!-- copied content of the style from the above link -->
</Style>
</UserControl.Resources>
<Grid ....>
<Grid x:Name="LayoutRoot">
<ScrollViewer Style="{StaticResource MyScrollViewerStyle}">
<!-- Content here -->
</ScrollViewer>
現在ScrollViewer看起來和以前一樣。不同的是,你現在可以開始玩Template
Setter
的風格來重新安排和定製ScrollViewer
。
0
相關問題
- 1. 需要幫助的網格
- 2. 需要幫助Zend表格
- 3. 需要幫助JSON格式
- 4. 需要幫助淡出格
- 5. 需要幫助jquery ui手風琴
- 6. silverlight scrollviewer風格
- 7. 需要幫助
- 8. 需要幫助
- 9. 需要幫助來「設置」一個REST風格的web服務
- 10. 需要C#服務器/客戶端風格程序的幫助
- 11. cssSandpaper.js幫助需要?
- 12. 需要ActionListener幫助!
- 13. 需要MySQL幫助
- 14. 需要Java幫助
- 15. 需要幫助JAVA
- 16. 需要幫助UIText
- 17. jquery幫助需要
- 18. RAZOR需要幫助
- 19. LINQTOSQL需要幫助
- 20. 需要幫助InstallShield
- 21. 需要onclick幫助
- 22. Javascript:setTimeout() - 需要幫助
- 23. HttpWebrequest需要幫助
- 24. 需要幫助TCHart
- 25. SimpleXML幫助需要
- 26. 需要幫助Ordereddict
- 27. 需要Hibernate幫助
- 28. 需要EJB幫助
- 29. 需要幫助update_attributes
- 30. GetShortPathName需要幫助