Building Tablet PC Applications

ROB JARRETT

Tablet PC 开发,有需要PDF的留下邮箱

目录
This text was added by using code.Building Tablet PC Applications......................................1
ROB JARRETT ...............................................................................................................1
PHILIP SU......................................................................................................................1
Chapter 3. Introduction to the Tablet PC Platform SDK.....................................................9
A Sort of Homecoming .............................................................................................................10
Finding the Right Operating System for the Job.......................................................17
Managed APIs .....................................................................................................................18
Ink Controls .........................................................................................................................20
COM Automation APIs ......................................................................................................21
Sample Applications .........................................................................................................23
Installing the Tablet PC Platform SDK..................................................................................26
System Requirements.......................................................................................................27
Getting the SDK..................................................................................................................28
Setting Up Your Environment.........................................................................................29
SETTING UP YOUR VISUAL STUDIO .NET ENVIRONMENT ..............31
NOTE .............................................................................................................................31
Anatomy of the Tablet PC Platform SDK .....................................................................37
NOTE .............................................................................................................................37
Overview of the Managed API.................................................................................................40
All That You Can’t Leave Behind ...................................................................................45
Design Goals of the API ...................................................................................................46
THE PRIME DIRECTIVE .......................................................................................49
WHAT’S COVERED BY THE MANAGED API..............................................49
WHAT’S NOT COVERED BY THE MANAGED API ...................................52
NOTE .............................................................................................................................54
Managed API Object Survey............................................................................................58
TABLET INPUT API................................................................................................59
Ink Data Management API................................................................................................64
Ink Recognition API...........................................................................................................67
Ink Control Comparison with Managed API ........................................................................70
Welcome to the Great Adventure...........................................................................................74
Chapter 4. Tablet PC Platform SDK: Tablet Input..............................................................75
Sample Applications .................................................................................................................76
Capturing Input from the Pen .................................................................................................77
NOTE .............................................................................................................................77
Requirement #1—Mouse Emulation..............................................................................78
NOTE .............................................................................................................................78
Requirement #2—Digital Ink............................................................................................79
Requirement #3—Pen-Based Actions ..........................................................................81
3 / 891
NOTE .............................................................................................................................82
Summing Up the Requirements .....................................................................................83
.Anatomy of the Tablet PC’s Tablet Input Subsystem......................................................83
Tablet Hardware..................................................................................................................85
NOTE .............................................................................................................................86
Chock-full of HID-y Goodness ........................................................................................86
NOTE .............................................................................................................................87
The Center of the TIS Universe: Wisptis.exe ..............................................................88
NOTE .............................................................................................................................89
GETTING INPUT FROM THE DRIVER............................................................90
PERFORMING MOUSE EMULATION ..............................................................91
DETECTING PEN-BASED ACTIONS ..............................................................96
NOTE .............................................................................................................................97
DISPATCHING EVENTS .......................................................................................98
MAKING SENSE OF IT ALL .............................................................................101
Winlogon Desktop Support ...........................................................................................103
What About Ink?...............................................................................................................104
Platform SDK Support for Tablet Input ..............................................................................104
Getting Ink from a Tablet................................................................................................105
SAY HELLO TO THE INKCOLLECTOR .......................................................105
NOTE ...........................................................................................................................106
SAMPLE APPLICATION: "HELLOINKCOLLECTOR"............................106
NOTE ...........................................................................................................................110
When Ink Is Not Enough.................................................................................................111
NOTE ...........................................................................................................................112
SAMPLE APPLICATION: HELLOINKOVERLAY ......................................113
CHANGING THE ERASER MODE ..................................................................122
THE INKCONTROL CLASS IN
THE BUILDINGTABLETAPPS LIBRARY ....................................................123
INKOVERLAY’S ATTACH MODE ...................................................................124
NOTE ...........................................................................................................................126
NOTE ...........................................................................................................................127
InkCollector Events .........................................................................................................127
NOTE ...........................................................................................................................128
INK STROKE EVENTS ........................................................................................129
PEN MOVEMENT EVENTS ................................................................................130
NOTE ...........................................................................................................................135
MOUSE TRIGGER EVENTS ..............................................................................135
TABLET HARDWARE EVENTS .......................................................................137
NOTE ...........................................................................................................................137
RENDERING EVENTS (INKOVERLAY ONLY) ..........................................138
INK EDITING EVENTS (INKOVERLAY ONLY) .........................................139
SAMPLE APPLICATION: INPUTWATCHER ..............................................143
ANALYZING THE EVENTS................................................................................166
4 / 891
TIP ................................................................................................................................170
InkOverlay Events............................................................................................................173
Specifying the Tablet Data to Capture—Packet Properties ..................................174
TIP ................................................................................................................................175
SAMPLE APPLICATION: PACKETPROPERTYWATCHER .................180
TIP ................................................................................................................................180
INK COORDINATES .............................................................................................198
Extending InkOverlay Behaviors .................................................................................198
Sample Application: TopOfPenErase .........................................................................200
Sample Application: ModelessSwitch ........................................................................207
Getting Introspective...............................................................................................................213
Tablets Collection ............................................................................................................214
Tablet Class .......................................................................................................................215
SAMPLE APPLICATION: DEVICEWALKER ..............................................218
Common Properties on InkCollector and InkOverlay.............................................227
Best Practices for InkCollector and InkOverlay...............................................................232
NewPackets and NewInAirPackets Events................................................................232
Choosing Desired Packet Properties..........................................................................233
Gesture Recognition .......................................................................................................233
Mouse Events....................................................................................................................234
Summary ....................................................................................................................................235
Chapter 5. Tablet PC Platform SDK: Ink Data Management, Part I .............................236
Ink and Stroke Objects ...........................................................................................................238
NOTE ...........................................................................................................................239
Introduction to the Ink, Stroke, and Strokes Classes.............................................242
THE INK CLASS ....................................................................................................243
THE STROKE CLASS ..........................................................................................245
THE STROKES CLASS .......................................................................................246
SAMPLE APPLICATION—STROKEIDVIEWER ........................................248
ANALYSIS OF STROKE ID BEHAVIOR ......................................................258
NOTE ...........................................................................................................................260
Using Strokes Collections .............................................................................................260
COLLECTION FUNCTIONALITY .....................................................................261
RECEIVING NOTIFICATION OF STROKE ADDITION OR REMOVAL
.......................................................................................................................................263
SAMPLE APPLICATION—INKSELECTOR .................................................264
Creation, Deletion, and Ownership of Stroke Objects ...........................................276
ADDING INK ............................................................................................................278
NOTE ...........................................................................................................................279
DELETING INK .......................................................................................................280
RECEIVING NOTIFICATION OF INK ADDITION AND DELETION ...283
SAMPLE APPLICATION—INKCOPY ............................................................284
SAMPLE APPLICATION—INKFACTORY....................................................294
Rendering Digital Ink...............................................................................................................304
5 / 891
Renderer Class .................................................................................................................305
CREATING AND MAINTAINING RENDERER OBJECTS .....................307
DRAWING INK ........................................................................................................308
SAMPLE APPLICATION—INKLAYERS .......................................................309
CONVERTING BETWEEN INK SPACE AND PIXELS ............................317
RENDERER TRANSFORMS—SCROLLING AND ZOOMING ..............318
SAMPLE APPLICATION—INKMAGNIFY ....................................................323
Adding Style—The DrawingAttributes Class............................................................339
ANTIALIASED.........................................................................................................342
FITTOCURVE PROPERTY.................................................................................343
NOTE ...........................................................................................................................345
IGNOREPRESSURE PROPERTY ...................................................................345
PENTIP ATTRIBUTE ............................................................................................346
RASTEROPERATION PROPERTY.................................................................347
USING THE DRAWINGATTRIBUTES PROPERTY ..................................348
NOTE ...........................................................................................................................348
SAMPLE APPLICATION—INKFORMATTER .............................................351
Special Rendering Effects .............................................................................................369
RENDERING SELECTION STATE..................................................................370
GLOWING INK ........................................................................................................373
TRULY TRANSPARENT INK ............................................................................375
PERFORMANCE IMPLICATIONS OF THESE METHODS ....................375
Summary ....................................................................................................................................376
Chapter 6. Tablet PC Platform SDK: Ink Data Management, Part II ............................378
Stroke Geometry ......................................................................................................................379
Computing the Bounding Box of a Stroke ................................................................379
THE GETBOUNDINGBOX METHOD..............................................................380
THE RENDERER CLASS’S MEASURE METHOD....................................383
CODE SNIPPET—DRAWBOUNDINGBOXES ............................................384
Retrieving the Points of a Stroke .................................................................................385
POLYLINE POINTS ..............................................................................................386
NOTE ...........................................................................................................................387
BÉZIER CONTROL POINTS .............................................................................387
CODE SNIPPET—DRAWPOINTS (DRAWS BÉZIER OR POLYLINE
POINTS OF INK) ....................................................................................................389
Computing Intersections of a Stroke..........................................................................391
CODE SNIPPET—DRAWINTERSECTIONS ................................................397
Retrieving and Setting the Packet Data of a Stroke................................................403
NOTE ...........................................................................................................................404
CODE SNIPPET—PRESSUREADJUST .......................................................406
Retrieving the Cusps of a Stroke .................................................................................408
CODE SNIPPET—DRAWCUSPS.....................................................................409
Putting It Together—the StrokeDataViewer Example.............................................412
SAMPLE APPLICATION—STROKEDATAVIEWER.................................412
6 / 891
Transforming Strokes .....................................................................................................433
SAMPLE APPLICATION—STROKEWARPER ...........................................436
Targeting and Hit-Testing Ink Strokes................................................................................444
Different Types of Hit-Testing.......................................................................................444
POINT-BASED ........................................................................................................445
RECTANGLE-BASED ..........................................................................................445
LASSO-BASED ......................................................................................................446
PERCENTAGE-BASED ENCLOSURE ..........................................................446
Hit-Testing Functions......................................................................................................450
NOTE ...........................................................................................................................451
COMPUTING THE NEAREST POINT ............................................................452
SAMPLE APPLICATION—INSERTREMOVESPACE ..............................453
SAMPLE APPLICATION—REALTIMELASSO ...........................................466
Splitting and Trimming Ink ....................................................................................................499
Splitting Strokes...............................................................................................................500
NOTE ...........................................................................................................................501
Clipping/Trimming Strokes............................................................................................501
SAMPLE APPLICATION—STROKECHOPPER.........................................502
NOTE ...........................................................................................................................522
NOTE ...........................................................................................................................524
Serialization, the Clipboard, and Drag and Drop .............................................................524
Serialization .......................................................................................................................524
PERSISTING STROKES COLLECTIONS ....................................................529
EXTENDED PROPERTY DATA .......................................................................530
SAMPLE APPLICATION—INKPERSIST ......................................................531
NOTE ...........................................................................................................................541
Using the Clipboard.........................................................................................................541
SAMPLE APPLICATION—INKCLIPPY.........................................................547
Implementing Drag and Drop........................................................................................555
SAMPLE APPLICATION—INKDRAGDROP ...............................................556
Summary ....................................................................................................................................563
Chapter 7. Tablet PC Platform SDK: Ink Recognition.....................................................564
Recognizer Architecture ........................................................................................................566
Text vs. Object Recognition ..........................................................................................567
Synchronous vs. Asynchronous Recognition .........................................................568
PARTIAL RECOGNITION ...................................................................................570
WHEN TO USE FOREGROUND AND BACKGROUND RECOGNITION
.......................................................................................................................................571
Recognition Results........................................................................................................572
Performing Simple Recognition...........................................................................................574
Recognizing Text..............................................................................................................575
SAMPLE APPLICATION—BASICRECO ......................................................575
Recognizing Application Gestures..............................................................................580
SPECIFYING APPLICATION GESTURES TO RECOGNIZE................581
7 / 891
RECEIVING APPLICATION GESTURE EVENTS .....................................593
SAMPLE APPLICATION—GESTUREPAD ..................................................594
Using the Recognition Classes ............................................................................................606
Obtaining a Recognizer to Use.....................................................................................608
Initiating a Recognition Session ..................................................................................610
THE RECOGNITION MODE...............................................................................611
PREFIX AND SUFFIX STRINGS .....................................................................614
THE CHARACTER AUTO-COMPLETE MODE ..........................................614
NOTE ...........................................................................................................................616
Supplying Strokes to the Recognizer .........................................................................617
Getting Results I: Easy Synchronous Recognition.................................................620
NOTE ...........................................................................................................................621
SAMPLE APPLICATION—INTERMEDIATERECO...................................621
Getting Results II: Electric Boogaloo (a.k.a. Harder Synchronous Recognition)
..............................................................................................................................................627
SAMPLE APPLICATION—ADVANCEDRECO ...........................................628
NOTE ...........................................................................................................................641
Getting Results III: The Final Chapter (a.k.a. Asynchronous Recognition)......642
SAMPLE APPLICATION—ASYNCRECO.....................................................644
Working with Recognition Results..............................................................................655
THE RECOGNITIONALTERNATE CLASS ..................................................657
SAMPLE APPLICATION—WORDSELECT .................................................662
SAMPLE APPLICATION—CORRECTIONUI ..............................................675
Storing Recognition Results .........................................................................................695
Recognition Properties...................................................................................................698
Improving Recognition Results....................................................................................703
FACTOIDS—CONTENT HINT...........................................................................703
WORD LISTS—CONTENT HINT .....................................................................712
DETERMINING IF A WORD IS SUPPORTED ............................................712
GUIDES—SPATIAL HINT...................................................................................713
Summary ....................................................................................................................................714
Chapter 8. Ink Controls...........................................................................................................716
Achtung Baby ...........................................................................................................................717
IMPORTANT .............................................................................................................719
InkEdit .........................................................................................................................................720
InkEdit Basics ...................................................................................................................721
BASIC PROPERTIES ...........................................................................................728
MOUSE-RELATED PROPERTIES ..................................................................733
NOTE ...........................................................................................................................734
BASIC PROPERTIES EXAMPLE ....................................................................736
Working with Ink...............................................................................................................742
ACCESSING INK WITH SELINKS ..................................................................742
TOGGLING INK DISPLAY WITH SELINKSDISPLAYMODE ................744
Recognizing Ink and Gestures .....................................................................................746
8 / 891
CHANGING RECOGNITION ..............................................................................746
RECOGNITION TIMING ......................................................................................752
GESTURES IN INKEDIT .....................................................................................756
NOTE ...........................................................................................................................763
InkEdit Parting Thoughts ...............................................................................................763
InkPicture ...................................................................................................................................767
NOTE ...........................................................................................................................768
Summary ....................................................................................................................................783
Part III. Advanced Tablet PC Topics ........................................................................................785
Chapter 9. Updating Existing Applications .......................................................................785
Even Better than the Real Thing ..........................................................................................786
User Benefits of Integration ..........................................................................................787
PEN-FRIENDLY USER INTERFACES...........................................................787
DIGITAL INK FEATURES ..................................................................................790
Business Benefits of Integration .................................................................................793
Technical Considerations ......................................................................................................795
Application Design ..........................................................................................................795
INKCOLLECTOR AND INKOVERLAY ..........................................................796
STORAGE .................................................................................................................798
CLIPBOARD ............................................................................................................801
NOTE ...........................................................................................................................802
UNDO..........................................................................................................................803
INK ARCHITECTURE...........................................................................................809
ACCESSIBILITY.....................................................................................................811
Performance ......................................................................................................................812
SPEED OF COMMON OPERATIONS ............................................................813
NOTE ...........................................................................................................................833
MEMORY AND STORAGE OF INK ................................................................841
NOTE ...........................................................................................................................842
NOTE ...........................................................................................................................850
InkPadJunior .............................................................................................................................855
Summary ....................................................................................................................................867
Part IV. Appendixes....................................................................................................................868
Appendix A. BuildingTabletApps Library Reference......................................................868
The InkInputPanel Class ........................................................................................................870
InkInputPanel ....................................................................................................................870
The InkControl and InkControl2 Classes...........................................................................870
NOTE ...........................................................................................................................871
InkControl...........................................................................................................................871
InkControl2 ........................................................................................................................871
InkOverlay ..........................................................................................................................872
InkInputPanel ....................................................................................................................872
The FormatInkDlg Class.........................................................................................................872
FormatInkDlg.....................................................................................................................873
9 / 891
DrawingAttributes ............................................................................................................873
Add NoteThe InkEx Class.........................................................................................................874
AddStrokesAtRectangle.................................................................................................874
The RendererEx Class ............................................................................................................874
InkSpaceToPixel...............................................................................................................875
PixelToInkSpace...............................................................................................................875
DrawSelected ....................................................................................................................875
DrawStrokeIds...................................................................................................................876
DrawBoundingBoxes ......................................................................................................876
DrawPoints.........................................................................................................................877
DrawIntersections............................................................................................................878
DrawCusps.........................................................................................................................879
The LassoUI Class ...................................................................................................................879
LassoUI...............................................................................................................................880
Start .....................................................................................................................................880
Continue .............................................................................................................................881
Render.................................................................................................................................881
Points ..................................................................................................................................881
BoundingRect ...................................................................................................................882
DotSpacing ........................................................................................................................882
DotSize................................................................................................................................882
DotBrush ............................................................................................................................883
The CopyAsTextDlg Class.....................................................................................................883
CopyAsTextDlg.................................................................................................................883
RecognitionResult ...........................................................................................................884
Appendix B. Tablet PC Hardware Guidelines ...................................................................884
Windows XP Tablet PC Edition Hardware Requirements..............................................885
Digitizer: .............................................................................................................................885
Power States: ....................................................................................................................887
Viewing Mode:...................................................................................................................889
Removal from Dock:........................................................................................................890
Legacy-Free:......................................................................................................................890
CTRL+ALT+DEL or Equivalent Functionality: ..........................................................891

Building Tablet PC Applications ROB JARRETT的更多相关文章

  1. 018.07 New BMW ICOM A3+B+C+D Plus EVG7 Controller Tablet PC with WIFI Function

    2018.07 New BMW ICOM A3+B+C+D Plus EVG7  Controller Tablet PC with WIFI Function Software Version : ...

  2. 通通WPF随笔(4)——通通手写输入法(基于Tablet pc实现)

    原文:通通WPF随笔(4)--通通手写输入法(基于Tablet pc实现) 从我在博客园写第一篇博客到现在已经有1年半了,我的第一篇博客写的就是手写识别,当时,客户需求在应用中加入手写输入功能,由于第 ...

  3. c#基于Tablet pc实现的手写输入

    需要安装Tablet pc,win7的话 直接在控制面板>程序和应用>添加组建里面勾选上添加 然后就是下面的程序了,看代码 设计文件 namespace 手写识别 { partial cl ...

  4. Building real-time dashboard applications with Apache Flink, Elasticsearch, and Kibana

    https://www.elastic.co/cn/blog/building-real-time-dashboard-applications-with-apache-flink-elasticse ...

  5. 微软职位内部推荐-Principal DEV Manager for Bing Client

    微软近期Open的职位: Title: Principal DEV Manager for Bing ClientGroup: Search Technology Center Asia, BingW ...

  6. [转]Amazon DynamoDB – a Fast and Scalable NoSQL Database Service Designed for Internet Scale Applications

    This article is from blog of Amazon CTO Werner Vogels. -------------------- Today is a very exciting ...

  7. C#判断PC是否支持触摸屏

    C#判断PC是否支持触摸屏 添加引用PresentationFrameworkSystem.Windows.SystemParameters.IsTabletPC 使用win32api [csharp ...

  8. PHP判断是手机端访问还是PC端访问网站

    Mobile_Detect 是一个轻量级的开源移动设备(手机)检测的 PHP Class, 它使用 User-Agent 中的字符串,并结合 HTTP Header,来检测移动设备环境. 这个设备检测 ...

  9. 【本人译作推荐】Windows 8应用开发:C#和XAML卷(原名:Building Windows 8 Apps with C# and XAML)

    [图书推荐] 译名:Windows 8应用开发:C#和XAML卷 原名:Building Windows 8 Apps with C# and XAML   编辑推荐 国内第一本使用XAML与C#语言 ...

随机推荐

  1. 02 flask 请求钩子、异常捕获、上下文、Flask-Script 扩展、jinja2 模板引擎、csrf防范

    一 请求勾子 在客户端和服务器交互的过程中,有些准备工作或扫尾工作需要处理,比如: 在请求开始时,建立数据库连接: 在请求开始时,根据需求进行权限校验: 在请求结束时,指定数据的交互格式: 为了让每个 ...

  2. Webpack实现路由懒加载的三种方式

    原文指路:https://blog.csdn.net/qq_37540004/article/details/78727063 第一种: 引入方式(正常引入): const router = new ...

  3. MySql之安装以及设置密码等

    1.MySQL的下载安装.简单应用及目录介绍 1.下载安装 windows10的:https://www.cnblogs.com/clschao/articles/9916971.html linux ...

  4. Selenium-WebDriver驱动对照表

    Chrome 对于chrome浏览器,有时候会有闪退的情况,也许是版本冲突的问题,我们要对照着这个表来对照查看是不是webdriver和chrome版本不对 chromedriver版本 支持的Chr ...

  5. Spring的几种注入bean的方式

    在Spring容器中为一个bean配置依赖注入有三种方式: · 使用属性的setter方法注入  这是最常用的方式: · 使用构造器注入: · 使用Filed注入(用于注解方式).   使用属性的se ...

  6. hdu1569-方格取数-二分图网络流

    方格取数(2) Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Su ...

  7. 十六、JAVA基础(堆和栈)

    一.堆和栈 堆和栈都是JAVA中的存储结构,也就是说,都是内存中存放数据的地方. 1.堆:(存放由new创建的对象和数组) 引用类型的变量,内存分配一般在堆上或者常量池(字符串常量,基本数据类型常量) ...

  8. 学习建一个spring-Mvc项目

    学习建一个spring-Mvc项目 首先要有jdk1.8以上,spring,mybatis,以及整合jar包,tomcat ,然后配置环境(前面有配置得方法). 1)右键new project,--& ...

  9. html 中一些不常见的标签

    标签 描述 <b> 定义粗体文本. <big> 定义大号字. <em> 定义着重文字. <i> 定义斜体字. <small> 定义小号字. ...

  10. web服务器/应用服务器/http服务器/中间件

    web服务器:只处理html静态页面不处理动态页面,如apache/nginx/iis等. 应用服务器:能处理html静态页面也能处理动态页面,如tomcat/weblogic/websphere/j ...