Author: spouliot
Date: 2007-10-20 12:20:59 -0400 (Sat, 20 Oct 2007)
New Revision: 87852
Added:
trunk/moon/test/xaml/test-inkpresenter-drawingattributes.xaml
trunk/moon/test/xaml/test-inkpresenter-height-width.xaml
trunk/moon/test/xaml/test-inkpresenter.xaml
Modified:
trunk/moon/test/xaml/README
Log:
more ink-related test cases, see README
Modified: trunk/moon/test/xaml/README
===================================================================
--- trunk/moon/test/xaml/README 2007-10-20 16:08:16 UTC (rev 87851)
+++ trunk/moon/test/xaml/README 2007-10-20 16:20:59 UTC (rev 87852)
@@ -1,12 +1,18 @@
NON-WORKING
-* test-path-group-2.xaml,
+* test-path-group-2.xaml
The XAML parser replace the first GeometryGroup with the second
- instead of merging both. Bug #82612
+ instead of merging both. Bug #325279
* test-path-group-stoke.xaml
Degenerate cases works like individual shapes being rendered (i.e.
no FillRule is applied) and some geometries can be non-degenerated.
- Note: also suffers from #82612
+ Note: also suffers from #325279
+
+* test-inkpresenter.xaml
+* test-inkpresenter-drawingattributes.xaml
+* test-inkpresenter-height-width.xaml
+
+ Work in progress
Added: trunk/moon/test/xaml/test-inkpresenter-drawingattributes.xaml
===================================================================
--- trunk/moon/test/xaml/test-inkpresenter-drawingattributes.xaml
2007-10-20 16:08:16 UTC (rev 87851)
+++ trunk/moon/test/xaml/test-inkpresenter-drawingattributes.xaml
2007-10-20 16:20:59 UTC (rev 87852)
@@ -0,0 +1,112 @@
+<Canvas xmlns="http://schemas.microsoft.com/client/2007" Width="400"
Height="400" Background="Black">
+ <InkPresenter Width="400" Height="400" Background="White">
+ <InkPresenter.Strokes>
+ <StrokeCollection>
+
+<!-- no drawing attributes == small black point -->
+ <Stroke>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (transparent colors) == no point -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#00000000"
OutlineColor="#00000000" Height="1" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (black with transparent outline) == very small grey
point -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF000000"
OutlineColor="#00000000" Height="1" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="60" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (transparent with black outline) == quite big black
point -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#00000000"
OutlineColor="#FF000000" Height="1" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="80" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (transparent with black outline) == identical to above
(quite big black point) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF000000"
OutlineColor="#FF000000" Height="1" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="100" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (black with transparent outline) == invisible -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF000000"
OutlineColor="#00000000" Height="0" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (transparent with black outline) == small black point
(but bigger than no drawing attributes) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#00000000"
OutlineColor="#FF000000" Height="0" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- drawing attributes (transparent with black outline) == identical to above
(quite big black point) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF000000"
OutlineColor="#FF000000" Height="0" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="160" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+ </StrokeCollection>
+ </InkPresenter.Strokes>
+
+<!-- cloned points using round rectangles -->
+
+ <Rectangle Fill="#FF000000" Canvas.Left="18.5" Canvas.Top="29.5"
Height="3" Width="3" RadiusX="1.5" RadiusY="1.5" />
+
+ <Rectangle Fill="#FFcccccc" Canvas.Left="59" Canvas.Top="30" Height="2"
Width="2" RadiusX="1" RadiusY="1" />
+ <Rectangle Fill="#FF000000" Stroke="#FF000000" Canvas.Left="77.5"
Canvas.Top="29.5" Height="5" Width="5" RadiusX="2.5" RadiusY="2.5" />
+ <Rectangle Fill="#FF000000" Stroke="#FF000000" Canvas.Left="97.5"
Canvas.Top="29.5" Height="5" Width="5" RadiusX="2.5" RadiusY="2.5" />
+
+ <Rectangle Fill="#FF000000" Stroke="#FF000000" Canvas.Left="138"
Canvas.Top="30" Height="4" Width="4" RadiusX="2" RadiusY="2" />
+ <Rectangle Fill="#FF000000" Stroke="#FF000000" Canvas.Left="158"
Canvas.Top="30" Height="4" Width="4" RadiusX="2" RadiusY="2" />
+ </InkPresenter>
+</Canvas>
Added: trunk/moon/test/xaml/test-inkpresenter-height-width.xaml
===================================================================
--- trunk/moon/test/xaml/test-inkpresenter-height-width.xaml 2007-10-20
16:08:16 UTC (rev 87851)
+++ trunk/moon/test/xaml/test-inkpresenter-height-width.xaml 2007-10-20
16:20:59 UTC (rev 87852)
@@ -0,0 +1,572 @@
+<Canvas xmlns="http://schemas.microsoft.com/client/2007" Width="400"
Height="400" Background="Black">
+ <InkPresenter Width="400" Height="400" Background="White">
+ <InkPresenter.Strokes>
+ <StrokeCollection>
+
+<!-- single point width-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="0" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) width-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="0" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="40" />
+ <StylusPoint X="20" Y="80" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) width-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="0" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="20" />
+ <StylusPoint X="80" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) width-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="0" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="40" />
+ <StylusPoint X="80" Y="80" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point height-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) height-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="40" />
+ <StylusPoint X="120" Y="80" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) height-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="20" />
+ <StylusPoint X="180" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) height-only stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="0"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="40" />
+ <StylusPoint X="180" Y="80" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+
+<!-- single point large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="1" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="1" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="140" />
+ <StylusPoint X="20" Y="180" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="1" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="120" />
+ <StylusPoint X="80" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="1" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="140" />
+ <StylusPoint X="80" Y="180" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point large-height stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="140" />
+ <StylusPoint X="120" Y="180" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="120" />
+ <StylusPoint X="180" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) large-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="1"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="140" />
+ <StylusPoint X="180" Y="180" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+
+<!-- single point double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="5" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="220" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="5" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="240" />
+ <StylusPoint X="20" Y="280" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="5" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="220" />
+ <StylusPoint X="80" Y="220" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="5" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="240" />
+ <StylusPoint X="80" Y="280" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point double-height stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="220" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="240" />
+ <StylusPoint X="120" Y="280" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="220" />
+ <StylusPoint X="180" Y="220" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) double-width stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="240" />
+ <StylusPoint X="180" Y="280" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+
+<!-- single point stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="320" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="340" />
+ <StylusPoint X="20" Y="380" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="320" />
+ <StylusPoint X="80" Y="320" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) stroke -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="340" />
+ <StylusPoint X="80" Y="380" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="320"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="340"
PressureFactor="0" />
+ <StylusPoint X="120" Y="380"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="320"
PressureFactor="0" />
+ <StylusPoint X="180" Y="320"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="340"
PressureFactor="0" />
+ <StylusPoint X="180" Y="380"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point stroke, half-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="220" Y="320"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) stroke, half-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="220" Y="340"
PressureFactor="0.5" />
+ <StylusPoint X="220" Y="380"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke, half-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="240" Y="320"
PressureFactor="0.5" />
+ <StylusPoint X="280" Y="320"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) stroke, half-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="240" Y="340"
PressureFactor="0.5" />
+ <StylusPoint X="280" Y="380"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="320"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="120" Y="340"
PressureFactor="0" />
+ <StylusPoint X="120" Y="380"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="320"
PressureFactor="0" />
+ <StylusPoint X="180" Y="320"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) stroke, no pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="140" Y="340"
PressureFactor="0" />
+ <StylusPoint X="180" Y="380"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- single point stroke, full-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="320" Y="320"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (vertical line) stroke, full-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="320" Y="340"
PressureFactor="1.0" />
+ <StylusPoint X="320" Y="380"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (horizontal line) double-width stroke, full-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="340" Y="320"
PressureFactor="1.0" />
+ <StylusPoint X="380" Y="320"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+<!-- two points (diagonal line) stroke, full-pressure -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FFFF0000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="340" Y="340"
PressureFactor="1.0" />
+ <StylusPoint X="380" Y="380"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+ </StrokeCollection>
+ </InkPresenter.Strokes>
+ </InkPresenter>
+</Canvas>
Added: trunk/moon/test/xaml/test-inkpresenter.xaml
===================================================================
--- trunk/moon/test/xaml/test-inkpresenter.xaml 2007-10-20 16:08:16 UTC (rev
87851)
+++ trunk/moon/test/xaml/test-inkpresenter.xaml 2007-10-20 16:20:59 UTC (rev
87852)
@@ -0,0 +1,205 @@
+<Canvas xmlns="http://schemas.microsoft.com/client/2007" Width="400"
Height="400" Background="Black">
+ <!-- InkPresenter draws like a canvas (and more) -->
+ <InkPresenter Width="400" Height="400" Background="White">
+ <InkPresenter.Strokes>
+ <StrokeCollection>
+ <!-- a single red point, no pressure factor (default)
-->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- a single red point with a black outline, no
pressure factor (default) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="20" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- a single green point with a black outline, 0
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF00FF00"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="60" Y="20"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- a single blue point with a black outline, 0.5
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="80" Y="20"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- a single white point with a black outline, 0.5
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFFFFFF"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="100" Y="20"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+
+ <!-- two red points, no pressure factor (default) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="40" />
+ <StylusPoint X="20" Y="60" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- two red points with a black outline, no pressure
factor (default) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="40" />
+ <StylusPoint X="40" Y="60" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- two green points with a black outline, 0 pressure
factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF00FF00"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="60" Y="40"
PressureFactor="0" />
+ <StylusPoint X="60" Y="60"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- two blue points with a black outline, 0.5 pressure
factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="80" Y="40"
PressureFactor="0.5" />
+ <StylusPoint X="80" Y="60"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- two white points with a black outline, 0.5
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFFFFFF"
OutlineColor="#FF000000" Height="10" Width="10"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="100" Y="40"
PressureFactor="1.0" />
+ <StylusPoint X="100" Y="60"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+
+ <!-- three red points, no pressure factor (default) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="20" Y="80" />
+ <StylusPoint X="40" Y="100" />
+ <StylusPoint X="20" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- three red points with a black outline, no pressure
factor (default) -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFF0000"
OutlineColor="#FF000000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="40" Y="80" />
+ <StylusPoint X="60" Y="100" />
+ <StylusPoint X="40" Y="120" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- three green points with a black outline, 0
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF00FF00"
OutlineColor="#FF000000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="60" Y="80"
PressureFactor="0" />
+ <StylusPoint X="80" Y="100"
PressureFactor="0" />
+ <StylusPoint X="60" Y="120"
PressureFactor="0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- three blue points with a black outline, 0.5
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FF0000FF"
OutlineColor="#FF000000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="80" Y="80"
PressureFactor="0.5" />
+ <StylusPoint X="100" Y="100"
PressureFactor="0.5" />
+ <StylusPoint X="80" Y="120"
PressureFactor="0.5" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+
+ <!-- three white points with a black outline, 0.5
pressure factor -->
+ <Stroke>
+ <Stroke.DrawingAttributes>
+ <DrawingAttributes Color="#FFFFFFFF"
OutlineColor="#FF000000" Height="10" Width="5"/>
+ </Stroke.DrawingAttributes>
+ <Stroke.StylusPoints>
+ <StylusPointCollection>
+ <StylusPoint X="100" Y="80"
PressureFactor="1.0" />
+ <StylusPoint X="120" Y="100"
PressureFactor="1.0" />
+ <StylusPoint X="100" Y="120"
PressureFactor="1.0" />
+ </StylusPointCollection>
+ </Stroke.StylusPoints>
+ </Stroke>
+ </StrokeCollection>
+ </InkPresenter.Strokes>
+ </InkPresenter>
+</Canvas>
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches