Windows 8 Store Apps 之 ScrollViewer
来源:互联网 发布:java爬虫十九 编辑:程序博客网 时间:2024/05/30 04:56
<Page x:Class="XamlDemo.Controls.ScrollViewer.Chaining" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:XamlDemo.Controls.ScrollViewer" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"> <Grid Background="Transparent"> <StackPanel Margin="120 0 0 0"> <ScrollViewer> <StackPanel> <TextBlock Text="我是参照物" FontSize="14.667" /> <!-- Chaining: 锁链,在触摸模式下,滚动本 ScrollViewer 如果超出了边界,则滚动其父 ScrollViewer 本例的测试方法:在触摸模式下,滚动 ScrollViewer 内的内容直至超出边界,超出边界后不要停下来继续滚动,通过“我是参照物”观察父 ScrollViewer 是否也被滚动 IsHorizontalScrollChainingEnabled - 是否启用水平方向上的 Chaining,默认值为 true IsVerticalScrollChainingEnabled - 是否启用垂直方向上的 Chaining,默认值为 true --> <ScrollViewer Name="scrollViewer" Width="400" Height="400" Margin="0 10 0 0" HorizontalAlignment="Left" HorizontalScrollMode="Enabled" VerticalScrollMode="Enabled" HorizontalScrollBarVisibility="Visible" VerticalScrollBarVisibility="Visible" IsHorizontalScrollChainingEnabled="{Binding IsChecked, ElementName=chkIsHorizontalScrollChainingEnabled}" IsVerticalScrollChainingEnabled="{Binding IsChecked, ElementName=chkIsVerticalScrollChainingEnabled}"> <Image Source="/Assets/Logo.png" Width="1000" /> </ScrollViewer> <StackPanel Orientation="Horizontal"> <CheckBox Name="chkIsHorizontalScrollChainingEnabled" Content="IsHorizontalScrollChainingEnabled" IsChecked="True" Margin="10 0 0 0" /> <CheckBox Name="chkIsVerticalScrollChainingEnabled" Content="IsVerticalScrollChainingEnabled" IsChecked="True" Margin="10 0 0 0" /> </StackPanel> </StackPanel> </ScrollViewer> </StackPanel> </Grid></Page>
<Page x:Class="XamlDemo.Controls.ScrollViewer.Zoom" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:XamlDemo.Controls.ScrollViewer" xmlns:sys="using:System" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"> <Grid Background="Transparent"> <StackPanel Margin="120 0 0 0"> <!-- Zoom - 放大/缩小 ZoomMode - 是否启用“放大/缩小”功能(Disabled, Enabled),默认值为 Enabled MaxZoomFactor - 内容放大的最大倍数,默认值 10 MinZoomFactor - 内容放大的最小倍数,默认值 0.1 --> <ScrollViewer Name="scrollViewer" Width="400" Height="400" HorizontalAlignment="Left" ZoomMode="Enabled" MaxZoomFactor="2" MinZoomFactor="0.5"> <Image Source="/Assets/Logo.png" Width="400" Height="400" /> </ScrollViewer> <Button Click="Button_Click_1" Content="放大/缩小到 0.1 倍" /> </StackPanel> </Grid></Page>原文地址http://www.cnblogs.com/webabcd/archive/2013/03/11/2953402.html
0 0
- Windows 8 Store Apps 之 ScrollViewer
- 重新想象 Windows 8 Store Apps (8)
- 重新想象 Windows 8 Store Apps (9)
- 重新想象 Windows 8 Store Apps (15)
- 重新想象 Windows 8 Store Apps (16)
- 重新想象 Windows 8 Store Apps (32)
- 重新想象 Windows 8 Store Apps (33)
- 重新想象 Windows 8 Store Apps (34)
- 重新想象 Windows 8 Store Apps (36)
- Windows Store apps开发[40]Windows 8开发书籍之Programming Windows®, 6th Edition
- Windows Store apps开发[57]Windows 8 开发31日
- Windows Store apps开发[28]在Windows 8 Apps中通过C#使用Web Service
- Windows 8 Store Apps xml资源自定义缓存
- Windows Store apps开发[76]企业部署Windows 8 Store 风格应用
- Windows Store apps开发[25]Metro style apps改名为Windows Store apps
- Windows Store apps开发[23]创建Windows Store应用程序包
- Windows Store apps开发[1]平台简介
- Windows Store apps开发[13]应用程序生命周期
- Android 本机号码的获取
- 设计模式
- mysql时间查询 .
- python 学习笔记 9 -- Python强大的自省简析
- 开源的游戏引擎irrlicht中不使用比较、条件、三元运算求最值与中值的代码
- Windows 8 Store Apps 之 ScrollViewer
- jdbc和dbcp
- C# 文件对话框选择文件夹
- 一个将“r”变为小叉的字体
- Windows句柄到底是什么
- 2014年1月6号,开始写技术博客了
- Android异步处理系列文章索引
- ajax中执行服务器返回的js脚本
- 梳理C/C++ 语言char,int,long,float,double,longlong的字节数