SlideShare a Scribd company logo
Essential Windows Phone 7 5 Application
Development with Silverlight 1st Edition Shawn
Wildermuth download
https://ebookgate.com/product/essential-windows-
phone-7-5-application-development-with-silverlight-1st-edition-
shawn-wildermuth/
Get Instant Ebook Downloads – Browse at https://ebookgate.com
Get Your Digital Files Instantly: PDF, ePub, MOBI and More
Quick Digital Downloads: PDF, ePub, MOBI and Other Formats
Windows Phone 7 Developer Guide Building connected
mobile applications with Microsoft Silverlight
Developer Series 1st Edition Dominic Betts
https://ebookgate.com/product/windows-phone-7-developer-guide-
building-connected-mobile-applications-with-microsoft-
silverlight-developer-series-1st-edition-dominic-betts/
Windows Phone 7 Secrets 1st Edition Paul Thurrott
https://ebookgate.com/product/windows-phone-7-secrets-1st-
edition-paul-thurrott/
Programming with Mobile Applications Android iOS and
Windows Phone 7 1st Edition Thomas J. Duffy
https://ebookgate.com/product/programming-with-mobile-
applications-android-ios-and-windows-phone-7-1st-edition-thomas-
j-duffy/
Windows 8 and Windows Phone 8 Game Development 1st
Edition Adam Dawes (Auth.)
https://ebookgate.com/product/windows-8-and-windows-phone-8-game-
development-1st-edition-adam-dawes-auth/
Professional Windows Phone 7 Game Development Creating
Games using XNA Game Studio 4 1st Edition Chris G.
Williams
https://ebookgate.com/product/professional-windows-phone-7-game-
development-creating-games-using-xna-game-studio-4-1st-edition-
chris-g-williams/
Pro Windows Phone App Development 3rd Edition Falafel
Software
https://ebookgate.com/product/pro-windows-phone-app-
development-3rd-edition-falafel-software/
Windows Phone 7 Recipes A Problem Solution Approach 1st
Edition Fabio Claudio Ferracchiati
https://ebookgate.com/product/windows-phone-7-recipes-a-problem-
solution-approach-1st-edition-fabio-claudio-ferracchiati/
Microsoft Silverlight 4 Business Application
Development Beginners Guide 1st New edition Edition
Cameron Albert
https://ebookgate.com/product/microsoft-silverlight-4-business-
application-development-beginners-guide-1st-new-edition-edition-
cameron-albert/
Windows 7 Secrets 1st Edition Paul Thurrott
https://ebookgate.com/product/windows-7-secrets-1st-edition-paul-
thurrott/
Essential Windows Phone 7 5 Application Development with Silverlight 1st Edition Shawn Wildermuth
Essential Windows
Phone 7.5
The award-winning Microsoft .NET Development Series was
established in 2002 to provide professional developers with the
most comprehensive, practical coverage of the latest .NET technologies.
Authors in this series include Microsoft architects, MVPs, and other
experts and leaders in the field of Microsoft development technologies.
Each book provides developers with the vital information and critical
insight they need to write highly effective applications.
Visit informit.com/msdotnetseries for a complete list of available products.
Microsoft
®
.NET Development Series
Essential Windows
Phone 7.5
Application Development
with Silverlight
Shawn Wildermuth
Upper Saddle River, NJ • Boston • Indianapolis • San Francisco
New York • Toronto • Montreal • London • Munich • Paris • Madrid
Capetown • Sydney • Tokyo • Singapore • Mexico City
Many of the designations used by manufacturers and sellers to distinguish their products are
claimed as trademarks. Where those designations appear in this book, and the publisher was aware
of a trademark claim, the designations have been printed with initial capital letters or in all capitals.
The .NET logo is either a registered trademark or trademark of Microsoft Corporation in the United
States and/or other countries and is used under license from Microsoft.
Microsoft, Windows, Visual Basic, Visual C#, and Visual C++ are either registered trademarks or
trademarks of Microsoft Corporation in the U.S.A. and/or other countries/regions.
The author and publisher have taken care in the preparation of this book, but make no expressed or
implied warranty of any kind and assume no responsibility for errors or omissions. No liability is
assumed for incidental or consequential damages in connection with or arising out of the use of the
information or programs contained herein.
The publisher offers excellent discounts on this book when ordered in quantity for bulk purchases
or special sales, which may include electronic versions and/or custom covers and content particular
to your business, training goals, marketing focus, and branding interests. For more information,
please contact:
U.S. Corporate and Government Sales
(800) 382-3419
corpsales@pearsontechgroup.com
For sales outside the United States, please contact:
International Sales
international@pearson.com
Visit us on the Web: informit.com/aw
Library of Congress Cataloging-in-Publication Data
Wildermuth, Shawn.
Essential windows phone 7.5 : application development with silverlight
/ Shawn Wildermuth.
p. cm.
Includes index.
ISBN 978-0-321-75213-0 (pbk. : alk. paper)
1. Windows phone (Computer file) 2. Silverlight (Electronic resource)
3. Operating systems (Computers) 4. Application software—Development.
5. Mobile computing—Programming. I. Title.
QA76.59.W54 2012
005.4’46—dc23
2011036842
Copyright © 2012 Pearson Education, Inc.
All rights reserved. Printed in the United States of America. This publication is protected by copy-
right, and permission must be obtained from the publisher prior to any prohibited reproduction,
storage in a retrieval system, or transmission in any form or by any means, electronic, mechanical,
photocopying, recording, or likewise. To obtain permission to use material from this work, please
submit a written request to Pearson Education, Inc., Permissions Department, One Lake Street,
Upper Saddle River, New Jersey 07458, or you may fax your request to (201) 236-3290.
ISBN-13: 978-0-321-75213-0
ISBN-10: 0-321-75213-9
Text printed in the United States on recycled paper at RR Donnelley in Crawfordsville, Indiana.
First printing, December 2011
To my friend and mentor, Chris Sells,
without whom I would have never learned
that the story is more important than the facts.
This page intentionally left blank
vii
Contents at a Glance
Figures xvii
Tables xxv
Foreword xxvii
Preface xxix
Acknowledgments xxxi
About the Author xxxiii
1 Introducing Windows Phone 1
2 Writing Your First Phone Application 25
3 XAML Overview 61
4 Controls 89
5 Designing for the Phone 139
6 Developing for the Phone 187
7 Phone Integration 219
8 Databases and Storage 305
9 Multitasking 337
10 Services 369
11 The Marketplace 431
Index 459
This page intentionally left blank
ix
Contents
Figures xvii
Tables xxv
Foreword xxvii
Preface xxix
Acknowledgments xxxi
About the Author xxxiii
1 Introducing Windows Phone 1
A Different Kind of Phone 1
Integrated Experiences 6
Phone Specifications 7
Input Patterns 9
Designing for Touch 10
Hardware Buttons 11
Keyboards 11
Sensors 13
Application Lifecycle 14
Driving Your Development with Services 15
Live Tiles 16
The Marketplace 18
Distributing Your Application through the Marketplace 18
Marketplace Submissions 19
Application Policies 20
x Contents
Content Policies 23
Where Are We? 24
2 Writing Your First Phone Application 25
Preparing Your Machine 25
Creating a New Project 27
Visual Studio 27
XAML 32
Designing with Blend 36
Adding Code 43
Working with Events 46
Debugging in the Emulator 47
Debugging with a Device 48
Using Touch 52
Working with the Phone 55
Where Are We? 59
3 XAML Overview 61
What Is XAML? 61
XAML Object Properties 63
Understanding XAML Namespaces 64
Naming in XAML 65
Visual Containers 66
Visual Grammar 70
Shapes 71
Brushes 72
Colors 73
Text 74
Images 75
Transformations and Animations 77
Transformations 77
Animations 80
XAML Styling 82
Understanding Resources 83
Understanding Styles 84
Where Are We? 87
xi
Contents
4 Controls 89
Controls in Silverlight 89
Simple Controls 91
Content Controls 97
List Controls 98
Phone-Specific Controls 99
Panorama Control 99
Pivot Control 102
Data Binding 105
Simple Data Binding 105
Using a DataTemplate 108
Improving Scrolling Performance 108
Binding Formatting 110
Element Binding 110
Converters 111
Data Binding Errors 113
Control Templates 114
Silverlight for Windows Phone Toolkit 119
AutoCompleteBox Control 119
ContextMenu Control 121
DatePicker and TimePicker Controls 122
ListPicker Control 124
LongListSelector Control 127
PerformanceProgressBar Control 131
ToggleSwitch Control 132
ExpanderView Control 133
PhoneTextBox Control 134
WrapPanel Layout Container 136
Where Are We? 138
5 Designing for the Phone 139
The Third Screen 139
It Is a Phone, Right? 143
Deciding on an Application Paradigm 144
Panorama 146
xii Contents
Pivot 147
Simple Pages 150
Microsoft Expression Blend 150
Creating a Project 150
A Tour around Blend 151
Blend Basics 159
Layout 159
Brushes 164
Creating Animations 169
Working with Behaviors 173
Phone-Specific Design 176
The ApplicationBar in Blend 176
Using the Panorama Control in Blend 179
Using the Pivot Control in Blend 182
Previewing Applications 185
Where Are We? 185
6 Developing for the Phone 187
Application Lifecycle 187
Navigation 190
Tombstoning 195
The Phone Experience 200
Orientation 201
Designing for Touch 203
Application Client Area 211
Application Bar 213
Understanding Idle Detection 215
The Tilt Effect 216
Where Are We? 218
7 Phone Integration 219
Using Vibration 219
Using Motion 220
Emulating Motion 223
Using Sound 226
Playing Sounds with MediaElement 226
xiii
Contents
Using XNA Libraries 227
Playing Sounds with XNA 228
Adjusting Playback 229
Recording Sounds 230
Contacts and Appointments 233
Contacts 233
Appointments 238
Alarms and Reminders 240
Creating an Alarm 242
Creating a Reminder 244
Accessing Existing Notifications 245
Using Tasks 246
Launchers 248
Choosers 257
Media and Picture Hubs 266
Accessing Music 266
Playing Music 268
Accessing Pictures 270
Storing Pictures 272
Integrating into the Pictures Hub 274
Integrating into the Music+Videos Hub 276
Working with the Camera 280
Using the PhotoCamera Class 280
Raw Hardware Access 284
The Clipboard API 287
Live Tiles 288
Main Live Tile 289
Secondary Tiles 290
Dual-Sided Live Tiles 292
Location APIs 293
Location Permission 293
Accessing Location Information 294
Emulating Location Information 300
Where Are We? 303
xiv Contents
8 Databases and Storage 305
Storing Data 305
Isolated Storage 306
Serialization 308
Local Databases 314
Getting Started 314
Optimizing the Context Class 320
Associations 324
Using an Existing Database 330
Schema Updates 332
Database Security 334
Where Are We? 335
9 Multitasking 337
Multitasking 337
Background Agents 338
Periodic Agent 340
Resource-Intensive Agent 348
Audio Agent 350
Background Transfer Service 360
Requirements and Limitations 360
Requesting Transfers 362
Monitoring Requests 363
Where Are We? 368
10 Services 369
The Network Stack 370
The WebClient Class 370
Accessing Network Information 373
Consuming JSON 376
Using JSON Serialization 377
Parsing JSON 379
Web Services 383
Consuming OData 387
How OData Works 388
xv
Contents
The URI 389
Using OData on the Phone 398
Generating a Service Reference for OData 398
Retrieving Data 399
Updating Data 401
Using Push Notifications 403
Push Notification Requirements 404
Preparing the Application for Push Notifications 405
Setting Up the Server for Push Notifications 407
Raw Notifications 410
Sending Toast Notifications 419
Creating Live Tiles 423
Handling Push Notification Errors 427
Where Are We? 429
11 The Marketplace 431
What Is the Marketplace? 431
How It Works 432
Charging for Apps 435
Getting Paid 438
Submitting Your App 439
Preparing Your Application 439
The Submission Process 445
After the Submission 451
Modifying Your Application 453
Dealing with Failed Submissions 454
Using Ads in Your Apps 457
Where Are We? 458
Index 459
This page intentionally left blank
xvii
Figures
FIGURE 1.1 Windows Phone Start screen 3
FIGURE 1.2 Phone screen real estate 3
FIGURE 1.3 The application bar in action 4
FIGURE 1.4 Panorama application 5
FIGURE 1.5 Last pane of a panorama application 5
FIGURE 1.6 Using Metro chrome, or not 6
FIGURE 1.7 Seven points of input 8
FIGURE 1.8 Metro’s interactive element sizes 10
FIGURE 1.9 Default keyboard 12
FIGURE 1.10 Contextual keyboards 12
FIGURE 1.11 Application lifecycle (tombstoning) 15
FIGURE 1.12 A tile in the hub 17
FIGURE 1.13 Updating tiles 17
FIGURE 1.14 Marketplace application submission process 19
FIGURE 2.1 Microsoft Visual Studio 2010 Express for Windows Phone 28
FIGURE 2.2 New Project dialog 29
FIGURE 2.3 Picking the phone version to target 29
FIGURE 2.4 The Visual Studio user interface 30
FIGURE 2.5 Enabling the toolbar 31
FIGURE 2.6 Using the emulator 31
FIGURE 2.7 The emulator 31
xviii Figures
FIGURE 2.8 Using the Visual Studio XAML design surface 33
FIGURE 2.9 Location of the Properties window 34
FIGURE 2.10 Contents of the Properties window 34
FIGURE 2.11 The changed property 35
FIGURE 2.12 Opening Blend directly in Visual Studio 36
FIGURE 2.13 The Blend user interface 37
FIGURE 2.14 Selecting an object in Blend 38
FIGURE 2.15 Selecting an object to edit in the Properties pane 38
FIGURE 2.16 Updating a property in Blend 39
FIGURE 2.17 Drawing in a container 40
FIGURE 2.18 Rounding the corners 40
FIGURE 2.19 Editing brushes 41
FIGURE 2.20 Picking a color 41
FIGURE 2.21 Inserting a TextBlock 42
FIGURE 2.22 Centering the TextBlock 42
FIGURE 2.23 Changing the text properties 43
FIGURE 2.24 Naming an element in the Properties window 45
FIGURE 2.25 Running the application 46
FIGURE 2.26 Using the Visual Studio debugger 48
FIGURE 2.27 Connected device 49
FIGURE 2.28 Your phone connected to the Zune software 49
FIGURE 2.29 Registering your device 50
FIGURE 2.30 Successfully registered developer phone 51
FIGURE 2.31 Changing the deployment to use a development phone 51
FIGURE 2.32 Running on a device 52
FIGURE 2.33 Dragging the ellipse 55
FIGURE 2.34 The SearchTask in action 57
FIGURE 2.35 Choosing a contact to retrieve an email address via the
EmailAddressChooserTask 59
FIGURE 2.36 Showing the selected email in a MessageBox 59
FIGURE 3.1 Path explained 72
FIGURE 3.2 Image stretching 77
FIGURE 3.3 Transformations in action 78
FIGURE 3.4 Entire container transformed 79
xix
Figures
FIGURE 4.1 TextBox control example 90
FIGURE 4.2 Software input panel (SIP) 92
FIGURE 4.3 Special SIP keys 92
FIGURE 4.4 Long-hold keys 93
FIGURE 4.5 Chat input scope 94
FIGURE 4.6 Simple button with simple content 97
FIGURE 4.7 Button with XAML content 97
FIGURE 4.8 List box 98
FIGURE 4.9 Panorama application 99
FIGURE 4.10 Panorama explained 100
FIGURE 4.11 Landscape sections 101
FIGURE 4.12 Pivot control 103
FIGURE 4.13 Pivot control in action 104
FIGURE 4.14 Looping pivot sections 104
FIGURE 4.15 Simple data binding 105
FIGURE 4.16 Changes in the source 107
FIGURE 4.17 Output window 113
FIGURE 4.18 Binding error shown in the Output window 114
FIGURE 4.19 Conversion error shown in the Output window 114
FIGURE 4.20 TemplatePart attribute 116
FIGURE 4.21 TemplateVisualState attribute 118
FIGURE 4.22 AutoCompleteBox example 120
FIGURE 4.23 ContextMenu example 121
FIGURE 4.24 Date picking user interface 123
FIGURE 4.25 Setting icons as “Content” 124
FIGURE 4.26 Time picking user interface 125
FIGURE 4.27 ListPicker example (closed) 125
FIGURE 4.28 ListPicker example (opened) 126
FIGURE 4.29 ListPicker example (full screen) 126
FIGURE 4.30 LongListSelector with groups 128
FIGURE 4.31 LongListSelector’s pop-up groups 128
FIGURE 4.32 ToggleSwitch example 132
FIGURE 4.33 ToggleSwitch components 132
FIGURE 4.34 ExpanderView in action 133
FIGURE 4.35 PhoneTextBox with the Hint and ActionIcon shown 134
xx Figures
FIGURE 4.36 PhoneTextBox’s length indication support 135
FIGURE 4.37 PhoneTextBox’s AcceptReturn functionality 136
FIGURE 4.38 Buttons in a StackPanel 137
FIGURE 4.39 Buttons in a WrapPanel 137
FIGURE 4.40 Buttons in a vertical WrapPanel 138
FIGURE 5.1 Foursquare.com 140
FIGURE 5.2 Phone-sized app 141
FIGURE 5.3 Panorama application 142
FIGURE 5.4 A sample Foursquare on Windows Phone 142
FIGURE 5.5 Sample application navigation 145
FIGURE 5.6 Single-page Windows Phone application 145
FIGURE 5.7 Sample panorama application 146
FIGURE 5.8 Panorama in the emulator 146
FIGURE 5.9 Pivot example 148
FIGURE 5.10 Pivot pages 149
FIGURE 5.11 Blend New Project dialog 150
FIGURE 5.12 Blend user interface 152
FIGURE 5.13 Blend toolbar 153
FIGURE 5.14 Projects panel 154
FIGURE 5.15 Assets panel 155
FIGURE 5.16 Objects and Timeline panel 155
FIGURE 5.17 Artboard 157
FIGURE 5.18 Item Tools panel 158
FIGURE 5.19 Searching in the Properties panel 159
FIGURE 5.20 Dragging a new control 160
FIGURE 5.21 Margin and alignment layout 160
FIGURE 5.22 Column and row gutters 161
FIGURE 5.23 Splitting the grid into rows 162
FIGURE 5.24 Modifying row/column properties 163
FIGURE 5.25 Sizing across rows 163
FIGURE 5.26 Sizing across rows with RowSpan 164
FIGURE 5.27 Brushes in the Properties panel 164
FIGURE 5.28 Converting a color to a resource 167
FIGURE 5.29 Creating a color resource 168
xxi
Figures
FIGURE 5.30 Applying a color resource 168
FIGURE 5.31 Creating a brush resource 169
FIGURE 5.32 Applying a brush resource 169
FIGURE 5.33 Storyboard basics 169
FIGURE 5.34 Creating a storyboard 170
FIGURE 5.35 Objects and Timeline panel with animation 170
FIGURE 5.36 Picking the animation point 171
FIGURE 5.37 Animation mode on the artboard 171
FIGURE 5.38 The ellipse animated 172
FIGURE 5.39 Animation values in the Objects and Timeline panel 172
FIGURE 5.40 RenderTransform in an animation 173
FIGURE 5.41 Closing a storyboard 173
FIGURE 5.42 Behaviors in the Assets panel 174
FIGURE 5.43 Applying a behavior 175
FIGURE 5.44 Changing behavior properties 175
FIGURE 5.45 Multiple behaviors 176
FIGURE 5.46 ApplicationBar explained 177
FIGURE 5.47 Adding an ApplicationBar 178
FIGURE 5.48 Adding items to the ApplicationBar 178
FIGURE 5.49 Selecting a built-in icon for an ApplicationBar icon 179
FIGURE 5.50 New panorama application 180
FIGURE 5.51 PanoramaItems in the Objects and Timeline panel 180
FIGURE 5.52 Panorama control user interface 181
FIGURE 5.53 PanoramaItem selection 181
FIGURE 5.54 Adding a PanoramaItem 182
FIGURE 5.55 Creating a pivot application 183
FIGURE 5.56 A pivot application 183
FIGURE 5.57 Pivot control user interface 184
FIGURE 5.58 Editing a PivotItem 184
FIGURE 5.59 Changing device properties 185
FIGURE 6.1 Important files in a new project 188
FIGURE 6.2 Page navigation explained 191
FIGURE 6.3 URI mapping to the files in the project 192
FIGURE 6.4 How tombstoning works 196
xxii Figures
FIGURE 6.5 Portrait orientation 201
FIGURE 6.6 Landscape left orientation 201
FIGURE 6.7 Landscape right orientation 202
FIGURE 6.8 Application client area 212
FIGURE 6.9 Untilted 216
FIGURE 6.10 Tilted 216
FIGURE 7.1 Accelerometer axes 221
FIGURE 7.2 Showing the Accelerometer window in the emulator 224
FIGURE 7.3 The Accelerometer window 225
FIGURE 7.4 An alarm 240
FIGURE 7.5 A reminder 241
FIGURE 7.6 Stacked notifications 242
FIGURE 7.7 Media player controls 253
FIGURE 7.8 PhoneCallTask confirmation 255
FIGURE 7.9 Allowing photo cropping 262
FIGURE 7.10 Music library objects 267
FIGURE 7.11 Displaying the albums and pictures 272
FIGURE 7.12 The apps in the Pictures hub 274
FIGURE 7.13 Tile layers 288
FIGURE 7.14 Opening the emulator’s Additional Tools sidebar 300
FIGURE 7.15 Selecting the Location tab 301
FIGURE 7.16 Location tab of the Additional Tools dialog 301
FIGURE 7.17 Using pins to create waypoints 302
FIGURE 7.18 Saving recorded data 302
FIGURE 8.1 The SQL query 319
FIGURE 8.2 SQL Server Compact Edition database as Content 330
FIGURE 9.1 Relationship between application and scheduled task 339
FIGURE 9.2 Adding a new Scheduled Task Agent project 341
FIGURE 9.3 Picking the Windows Phone Scheduled Task Agent 341
FIGURE 9.4 Adding a reference to the Scheduled Task Agent project 344
FIGURE 9.5 The PeriodicTask’s description in the management user
interface 346
xxiii
Figures
FIGURE 9.6 The Universal Volume Control (UVC) in action 351
FIGURE 9.7 Adding an audio agent to your project 352
FIGURE 9.8 Making a reference to the audio agent project 353
FIGURE 10.1 Adding a service reference 383
FIGURE 10.2 The Add Service Reference dialog 384
FIGURE 10.3 Service files displayed 385
FIGURE 10.4 Adding a service reference to an OData feed 399
FIGURE 10.5 Adding a using statement to the data service 400
FIGURE 10.6 Push notification message flow 404
FIGURE 10.7 Debugging push notifications 420
FIGURE 10.8 A toast message 420
FIGURE 10.9 Tile layers 424
FIGURE 11.1 The Marketplace 432
FIGURE 11.2 The Marketplace in Zune 432
FIGURE 11.3 Submission process 433
FIGURE 11.4 The App Hub 434
FIGURE 11.5 Capability detection results 442
FIGURE 11.6 Works in the dark theme 444
FIGURE 11.7 Does not work in the light theme 444
FIGURE 11.8 Accessing your “dashboard” 445
FIGURE 11.9 Starting the submission process 446
FIGURE 11.10 Step 1 of the submission process 446
FIGURE 11.11 Filling in the descriptive fields 448
FIGURE 11.12 Pricing your app 449
FIGURE 11.13 Publish and testing options 450
FIGURE 11.14 Submission confirmation 450
FIGURE 11.15 Application lifecycle page 451
FIGURE 11.16 My Apps page 452
FIGURE 11.17 Deep link 453
FIGURE 11.18 Application actions 454
FIGURE 11.19 A failure report 455
This page intentionally left blank
xxv
Tables
TABLE 1.1 Integrated Experiences 7
TABLE 1.2 Hardware Specifications 8
TABLE 1.3 Hardware Inputs 9
TABLE 1.4 Sample Keyboard Layouts 13
TABLE 1.5 Sensors 13
TABLE 1.6 Microsoft Phone Services 16
TABLE 2.1 Windows Phone Developer Tools Requirements 26
TABLE 3.1 Visual Containers 67
TABLE 3.2 Grid Row and Column Sizing 69
TABLE 3.3 Brush Types 73
TABLE 3.4 Transformation Types 79
TABLE 4.1 Common InputScope Values 94
TABLE 4.2 RichTextBox Markup Tags 96
TABLE 4.3 Data Binding Modes 107
TABLE 5.1 New Project Types in Blend 151
TABLE 5.2 Row/Column Sizing Icons 162
TABLE 5.3 Brush Editors 165
TABLE 5.4 Blend Behaviors 174
xxvi Tables
TABLE 6.1 Manipulation Events 207
TABLE 6.2 UIElement Touch Events 211
TABLE 7.1 FilterKind Enumeration 234
TABLE 7.2 Launchers 246
TABLE 7.3 Choosers 247
TABLE 7.4 MediaPlaybackControls Enumeration 253
TABLE 9.1 Scheduled Task Limitations 340
TABLE 10.1 OData HTTP Verb Mappings 388
TABLE 10.2 OData Query Options 391
TABLE 10.3 $filter Operators 393
TABLE 10.4 $filter Functions 394
TABLE 10.5 Push Notification Response Headers 414
TABLE 10.6 Response Codes and Header Status Codes 415
TABLE 10.7 ChannelErrorType Enumeration 429
TABLE 10.8 ChannelPowerLevel Enumeration 429
TABLE 11.1 International Pricing Example 436
TABLE 11.2 Application Images 443
TABLE 11.3 Advertising Vendors for the Phone 457
xxvii
Foreword
When Shawn asked me to write a foreword for his Windows Phone devel-
opment book, I had a couple of reactions. First, that they must really be
scraping the bottom of the barrel if they have asked me to write anything.
There are so many people who actually help bring the product to market
who never really get the credit they deserve. While I am honored that I
was asked to write this, based in part on my public role on the team, the
engineering team that designed and built this amazing product are the real
heroes. The product itself is amazing, but the right application platform,
which enables the amazing Metro apps and games to be built, is a devel-
oper’s playground. I do this to honor them.
My second reaction was to think about the huge value Shawn has in
the Microsoft ecosystem. As an eight-time MVP and Silverlight Insider,
Shawn’s contributions are highly valued both for their content as well as
for their reach. When Shawn speaks, you know that he has the developer
in mind: He is a developer’s developer. Without individuals like Shawn, it
would be tough (if possible at all) for Microsoft to have built our developer
ecosystem over the last three decades. I do this to honor him.
My last reaction was one of panic. I have never written a foreword
before, so I was at a bit of a loss as to what I should say. I figure if you are
buying this book, you did so of your own volition, and not on the strength
of what I have to say here. However, if you are reading the foreword with
xxviii Foreword
an eye toward confirming your belief that Windows Phone is where it’s at,
well, for that I can be accommodating. I do this to honor you.
With the initial release of Windows Phone, and the subsequent pair-
ing with Nokia, Microsoft is investing in building the third ecosystem for
mobile developers. The canvas with which mobile developers can work
on Windows Phone is unlike any other platform, whereby developers can
create simply gorgeous apps with more focus on the user experience than
tinkering with the innards of a convoluted framework. Metro apps come
alive on the screen, and you will be able to build deeply engaging applica-
tions using Live Tiles.
Windows Phone 7.5 is an updated release, codenamed “Mango,” and
carries with it the tagline “Put people first.” We think the same way about
the developer platform. We aim to put developers first. The book you are
holding might be your first step on your journey to building Windows
Phone apps. It may be a refresher course. Either way, with Shawn’s guid-
ance, we know that you will come away from this experience feeling great
about your prospects of building amazing mobile experiences for Windows
Phone, and a firm belief that Microsoft puts the developers first when we
think about Windows Phone. Every developer matters. Every. Single. One.
—Brandon Watson
Microsoft Corporation
xxix
Preface
I have never owned a PalmPilot. But I have owned palmtops and smart-
phones. I dived into writing software for a plethora of different devices but
never got very far. My problem was that the story of getting software onto
the phones was chaotic and I didn’t see how the marketing of software
for phones would lead to a successful product. In the intervening years, I
got distracted by Silverlight and Web development. I didn’t pay attention
as the smartphone revolution happened. I was happily neck-deep in data
binding, business application development, and teaching XAML.
The smartphone revolution clearly started with the iPhone. What I find
interesting is that the iPhone is really about the App Store, not the phone.
It’s a great device, but the App Store is what changed everything, provid-
ing a simple way to publish, market, and monetize applications for these
handheld powerhouses that everyone wanted. Of course, Apple didn’t
mean to do it. When the original iPhone shipped, Apple clearly said that
Safari (its Web browser) was the development environment. With the pres-
sure of its OS X developer community, Apple relented and somewhat acci-
dentally created the app revolution.
When it was clear that I had missed something, I dived headlong into
looking at development for phones again. I had an Android phone at the
time, so that is where I started. Getting up to speed with Eclipse and Java
wasn’t too hard, but developing for the phone was still a bit of a chore. The
development tools just didn’t seem to be as easy as the development I was
xxx Preface
used to with Visual Studio and Blend. In this same time frame, I grabbed
a Mac and tried my hand at Objective-C and Xcode to write something
simple for the iPhone. That experience left me bloodied and bandaged. I
wanted to write apps, but since it was a side effort, the friction of the tool
sets for Android and iPhone left me wanting, and I put them aside.
Soon after my experience with iPhone and Android, Microsoft took
the covers off its new phone platform: Windows Phone 7. For me, the real
excitement was the development experience. At that point I’d been teach-
ing and writing about Silverlight since it was called WPF/E, so the ability
to marry my interest in mobile development to my Silverlight knowledge
seemed like a perfect match.
I’ve enjoyed taking the desktop/Web Silverlight experience I have and
applying the same concepts to the phone. By being able to use Visual Stu-
dio and Blend to craft beautiful user interface designs and quickly go from
prototype to finished application, I have found that the workflow of using
these tools and XAML makes the path of building my own applications
much easier than on other platforms.
In the middle of this learning process Microsoft continued to mature the
platform by announcing and releasing Windows Phone 7.5 (code-named
Mango). I was left questioning whether to finish my Windows Phone 7
book or rush forward and mold all the new features of Windows Phone
7.5 into a book for this next version of the phone. Obviously you know the
answer to that question.
It has been a long road to get the right story for this book, and to help
both beginners and existing Silverlight developers to learn from the book.
My goal was always to allow readers to get started writing apps quickly,
while also including the information that leads to great apps. Because of
the relative size of these minicomputers we keep in our pockets, knowing
when to pull back is often the key to a great application. As you will see
throughout this book, my goal has been to help you build great apps, not
rich applications. This means I will try to hold your hand as you read the
book, but I will also challenge your assumptions about how you approach
the process of building applications for the phone.
xxxi
Acknowledgments
Writing a book is a team sport. Anyone who thinks for a moment that writ-
ing a book requires that you sit in a dark room and craft words that magi-
cally get bound into Amazon currency hasn’t been through the sausage
factory that is book writing. The fact is that I may have the skills to get words
down on virtual paper, but I am not good at much of the rest of the process.
It takes a strong editor who knows how to dole out praise and pressure in
equal amounts. It takes technical reviewers who aren’t afraid to ruffle your
feathers. It takes production people to take the mess of Visio ramblings
you call figures and create something the reader will understand. Finally,
it takes an army of people to listen to your questions about the ambiguity
of writing a book based on a beta version of a product . . . and who will not
stop responding to your constant pestering. So I’d like to thank my army of
people by acknowledging their real contributions (in no particular order).
First and foremost, I want to thank my editor at Addison-Wesley, Joan
Murray. I am not an easy author to work with, and she’s been a trouper in
getting me to stick to deadlines and coercing me to make the right deci-
sions, not just the easy ones. The rest of the people at Addison-Wesley
that I’ve had the pleasure to work with are all great, too. Of special note,
Christopher Cleveland did a great job picking up the role of developmen-
tal editor in the middle of the book, and has been great through the whole
process.
xxxii Acknowledgments
To the litany of people on the Silverlight Insiders Mailing List and the
Windows Phone 7 Advisors Mailing List, I would like to thank you for
your patience as I pestered the lists with endless questions and hyperbolic
rants. You all helped shape this book, even if you didn’t realize it.
During this process, my blog’s readers and my followers on Facebook
and Twitter remained a consistent sounding board. My polls and open
questions helped me shape what is and isn’t in this book. For that I am
indebted to you.
I also want to thank my terrific technical reviewers, Jeremy Likeness,
Ambrose Little, and Bruce Little. Not only did they help me find the tons
of places I just plain got it wrong, but they also helped me when the story
got off track and I missed that key piece of the puzzle. Of particular note, I
want to thank Ambrose for his tenacious adherence to the designer’s voice.
He helped me make sure I wasn’t coddling the developers into bad user
experience design.
To anyone else I forgot to mention, I apologize.
—Shawn Wildermuth
November 2011
http://wildermuth.com
@shawnwildermuth
xxxiii
About the Author
During his twenty-five years in software development, Shawn Wilder-
muth has experienced a litany of shifts in software development. These
shifts have shaped how he understands technology. Shawn is a nine-time
Microsoft MVP, a member of the INETA Speaker’s Bureau, and an author
of several books on .NET. He is also involved with Microsoft as a Silver-
light Insider and a Data Insider. He has spoken at a variety of interna-
tional conferences, including TechEd, MIX, VSLive, OreDev, SDC, WinDev,
DevTeach, DevConnections, and DevReach. He has written dozens of arti-
cles for a variety of magazines and websites including MSDN, DevSource,
InformIT, CoDe Magazine, ServerSide.NET, and MSDN Online. He is cur-
rently teaching workshops around the United States through his training
company, AgiliTrain (http://agilitrain.com).
This page intentionally left blank
1
1
Introducing Windows Phone
T
o some, the cell phone is an annoying necessity; to others, it’s a
critical need. Being able to use a phone to make calls everywhere
has really changed the way people communicate. In the past few
years these phones have taken another leap forward. With the introduc-
tion of iPhone and Android devices, the consumer market for an always-
connected device that can interact with the Internet, run applications, and
make phone calls has changed people’s relationship with their phone. It
has also raised the bar for consumer-level devices. Consumers now expect
their phones to also function as GPSs, gaming devices, and Internet tablets.
For some consumers, their phones are now their primary connections to
the Internet, replacing the desktop/laptop computer for the first time. As
developers, our challenge is to find the best way to create the experiences
the user needs. Windows Phone provides the platform, and Silverlight is
the engine to power those experiences.
A Different Kind of Phone
When Microsoft originally unveiled Windows Phone 7 many skeptics
expected the phone would simply try to play catch-up with Apple’s and
Google’s offerings. Microsoft had other plans, though. The new operating
system for the phone was a departure from existing offerings from the other
mobile operating system vendors (primarily Apple, Research in Motion,
2 Chapter 1: Introducing Windows Phone
and Google). Instead of just mimicking the icon pattern screens that iPhone
and Android seemed to love, Microsoft thought in a different way. Applica-
tion and operating system design is defined in a new design language code-
named Metro.1
This design language defines a set of guidelines and styles
for creating Windows Phone applications. The design of the Start screen
laid out by Metro is similar to other smartphone designs in that it is a list of
icons. Instead of separating the icons into pages, Windows Phone lets users
scroll through the icons. Windows Phone is also differentiated from other
smartphones in that each icon can include information about the applica-
tion. These icons are called Live Tiles, as shown in Figure 1.1.
What Is a Design Language?
Developers think about a language as a set of textual expressions that
describe some machine operation(s). For designers, it is a set of rules for
defining the look and feel of a set of applications (or an entire operating
system in this case). Wikipedia.org defines it more generally as “. . . an
overarching scheme or style that guides the design of a complement of
products or architectural settings.”
The Start screen should be a place where users can quickly review the
status of the phone. The Live Tiles will give user information such as the
number of missed phone calls and the number of email or SMS messages
waiting, or even third-party information such as the current weather.
When you develop your own applications you can either create a simple
icon for the Start screen or build a Live Tile for your users.
For applications, the Windows Phone screen is divided into three areas
in which the user can interact with the phone: the system tray, the logical
client, and the application bar (see Figure 1.2).
The system tray area is managed by the phone’s operating system.
This is where the time, signal strength, and alerts will appear to the user.
Most applications will leave this area of the screen visible to the user. Some
1. UIDesignandInteractionGuideforWindowsPhone:http://shawnw.me/wpmetroguide
3
A Different Kind of Phone
FIGURE 1.1 Windows Phone Start screen
FIGURE 1.2 Phone screen real estate
4 Chapter 1: Introducing Windows Phone
applications (e.g., games) may hide this area, but you should only do so
when critical to the success of your application.
The logical client area is where your application will exist. This area
shows your user interface and any data and points of interaction.
The application bar shows options for your application. While using
the application bar is not a requirement, it is a very common practice as it
gives users access to your application’s options and menus. For example,
Figure 1.3 shows a simple note-taking application that uses the applica-
tion bar to allow users to create new notes or show the menu (note that the
ellipsis can be clicked to open the list of menu items).
One big distinction that users will see in many of the applications built
into Windows Phone is the use of hubs. The central idea of a hub is to pro-
vide a starting point to get the user to use natural curiosity to learn what is
available in the application. Usually these hubs take the form of applica-
tions that are larger than the phone screen. Instead of the typical page-based
FIGURE 1.3 The application bar in action
5
A Different Kind of Phone
applications that are fairly commonplace on smartphones, the Metro style
guide introduces something called a panorama application. For panorama
applications the phone is used as a window that looks into a larger applica-
tion surface. You’ll notice in Figure 1.4 that the content of the screen takes
up most of the horizontal real estate, but the next section of the panorama
application shows up on the right side of the screen to help the user under-
stand that there is more content.
As the user navigates through the panorama application, the virtual
space is moved within the window. For example, in Figure 1.5 you can see
how, after sliding the application to the left, the rightmost part of the pano-
rama becomes visible.
FIGURE 1.4 Panorama application
FIGURE 1.5 Last pane of a panorama application
6 Chapter 1: Introducing Windows Phone
The use of the panorama application results in a simple but powerful
user interface design that users should find very intuitive.
By following the guidelines specified by Metro, you can create applica-
tions that should be consistent with the rest of the phone, while giving you
the freedom to create applications of any kind. In this way, Metro helps by
defining basic ideas of how a Windows Phone application should look so
that the user can see complete consistency. At the same time, Metro says
you can simply take over the entire user interface and not use the basic
ideas of the Metro chrome, leaving you the flexibility to create either cus-
tom experiences or applications that look like they belong on the phone.
Figure 1.6 shows example apps with and without the chrome applied.
Integrated Experiences
One of the main purposes of the phone is to be an integrated platform on
which applications can interact with each other and with the core phone
experiences. This means you can write applications that integrate with the
phone in unprecedented ways. Table 1.1 outlines some of the core experi-
ences users will be able to interact with and use on the phone.
FIGURE 1.6 Using Metro chrome, or not
7
Phone Specifications
As developers, your code might or might not look like the code in tra-
ditional applications. Because you can write straightforward applications
that can be launched in a traditional sense, the integrated experiences let
your applications also interact with and even be embedded into these
experiences. This means you can write applications that extend and power
these experiences.
Phone Specifications
For Windows Phone, the stakes were high in terms of Microsoft’s ability
to not only create the software but also encourage its partners to build the
phone. Learning a lesson from its past Windows Mobile platform, Micro-
soft decided to be very specific about the hardware to ensure a great user
experience while giving phone designers some flexibility with feature sets
so that they could compete with one another. Table 1.2 shows the hardware
requirements.
In addition, Windows Phone has physical requirements. The most obvi-
ous of these is that each phone must have seven standard inputs, as shown
in Figure 1.7.
Table 1.3 lists and describes these seven hardware inputs.
TABLE 1.1 Integrated Experiences
Experience Description
People The people on your phone, including contacts and past phone
calls/SMS messages
Office Integration with email, Word, Excel, and PowerPoint files
Music+Videos The media on your device
Marketplace Access to try, buy, and install applications on the phone
Pictures View, share, and take pictures on your device
Games Playing games on the device; this includes Xbox Live
integration
8 Chapter 1: Introducing Windows Phone
TABLE 1.2 Hardware Specifications
Category Requirement
Screen resolution WVGA (480 x 800)
Capacitive touch At least four points of touch support
Memory 256MB RAM, 8GB Flash
Sensors A-GPS, Accelerometer, Compass, Light and Proximity, Gyro
CPU ARM7 Scorpion/Cortex or better (typically 1GHz+)
GPU DirectX 9 acceleration
Camera 5 megapixels minimum, flash required
Bluetooth Bluetooth 2.1 + EDR; Bluetooth profiles provided are Hand-Free
Profile (HFP), Headset Profile (HSP), Advanced Audio Distribu-
tion Profile (A2DP), and Phone Book Access Profile (PBAP)
Multimedia Codec acceleration required; support for DivX 4, 5, and 6 as well
as H.264 High Profile required (High Profile is used by Blu-ray)
Wi-Fi 802.11g radio required
Radio FM radio receiver required
FIGURE 1.7 Seven points of input
9
Input Patterns
Now that we have seen what the phone consists of, let’s see how users
will interact with the phone.
Input Patterns
You are the developer. You want users to want to use your applications.
That means you must deal with the different ways the phone can accept
user input. Developing for the Web or desktop means you are primarily
dealing with designing for the keyboard and mouse. But when developing
for the phone, you have to change the way you look at input and consider
that the user is going to interact with your application in different ways.
Interaction patterns for the phone include touch, keyboards (hardware and
software), hardware buttons, and sensors.
TABLE 1.3 Hardware Inputs
Input Expected Behavior
1 Power button When powered off, a long press will power on the device.
If powered on and screen is active, will turn off screen and
lock device. If screen is off, will enable screen and present
unlock UI.
2 Volume
control
A rocker switch will adjust volume for current activity’s
sound profile (e.g., phone call volume while on a call).
Pressing volume during a phone call will disable the ringer.
Adjusting volume when no activity is presently happening
will allow user to switch between sound profiles.
3 Touch screen The capacitive touch screen will support at least four points
of touch.
4 Camera button A long press on this dedicated button will launch the camera
application.
5 Back button This button issues a “back” operation. This may take the
user back in an individual application or from one applica-
tion to the previous application as presented by the page
API.
6 Start button This takes the user to the Start screen of the device.
7 Search button This launches the search experience to allow searching
across the device.
10 Chapter 1: Introducing Windows Phone
Designing for Touch
The Metro design language is specifically constructed to make sure the
interface is treating touch as a first-class citizen and that the interface
requires no training (i.e., is intuitive). By building a design language that
defines the elements of a touch-based interface, Microsoft has made it eas-
ier to build such interfaces. The design language includes guidelines for
what touch gestures are supported, as well as how to space and size ele-
ments for finger-size interactions. Figure 1.8 shows an example from Metro
to define the minimum sizes for touch points and their spacing.
Metro also defines the types of interactions (e.g., touch gestures) the
device supports. Most of these interactions are well-worn gestures that
have been the vocabulary of other touch devices such as the iPhone, Zune
HD, and Android. These interactions include
• Single touch:
− Tap
− Double-Tap
− Pan
− Flick
− Touch and Hold
• Multitouch:
− Pinch/Stretch/Rotate
2 mm/8 px
Minimum Space
between Touch
Targets
7 mm/26 px
Minimum
Object
Size
9 mm/34 px
Touch Target
FIGURE 1.8 Metro’s interactive element sizes
Discovering Diverse Content Through
Random Scribd Documents
scene in the house of Castlewood with the Prince, reveals her true
nature and quits the room in a rage. The supposed author writes:
“Her keen words gave no wound to Mr. Esmond; his heart was too
hard. As he looked at her, he wondered that he could ever have
loved her.... The Prince blushed and bowed low, as she gazed at him
and quitted the chamber. I have never seen her from that day.”
Thackeray made this slip on purpose. He wanted us to feel the
reality of the man who is trying to tell his own story in the third
person.
This, after all, is the real value of the book. It is not only a
wonderful picture of the Age of Queen Anne, its ways and customs,
its manner of speech and life, its principal personages—the red-
faced queen, and peremptory Marlborough, and smooth Atterbury,
and rakish Mohun, and urbane Addison, and soldier-scholar Richard
Steele—appearing in the background of the political plot. It is also,
and far more significantly, a story of the honour of a gentleman—
namely, Henry Esmond—carried through a life of difficulty, and
crowned with the love of a true woman, after a false one had failed
him.
Some readers profess themselves disappointed with the
dénouement of the love-story. They find it unnatural and
disconcerting that the hero should win the mother and not the
daughter as the guerdon of his devotion. Not I. Read the story more
closely.
When it opens, in the house of Castlewood, Esmond is a grave,
lonely boy of twelve; Lady Castlewood, fair and golden-haired, is in
the first bloom of gracious beauty, twenty years old; Beatrix is a dark
little minx of four years. Naturally, Henry falls in love with the mother
rather than with the daughter, grows up as her champion and
knight, defends her against the rakishness of Lord Mohun, resolves
for her sake to give up his claim to the title and the estate. Then
comes the episode of his infatuation by the wonderful physical
beauty of Beatrix, the vixen. That madness ends with the self-
betrayal of her letter of assignation with the Prince, and her
subsequent conduct. Esmond returns to his first love, his young love,
his true love, Lady Castlewood. Of its fruition let us read his own
estimate:
“That happiness which hath subsequently crowned it, cannot be
written in words; it is of its nature sacred and secret, and not to be
spoken of, though the heart be ever so full of thankfulness, save to
Heaven and the One Ear alone—to one fond being, the truest and
tenderest and purest wife ever man was blessed with.”
III
I have left myself scant space to speak of Thackeray’s third phase
in writing—his work as a moralist. But perhaps this is well, for, as he
himself said, (and as I have always tried to practise), the preacher
must be brief if he wishes to be heard. Five words that go home are
worth more than a thousand that wander about the subject.
Thackeray’s direct moralizings are to be found chiefly in his
lectures on “The Four Georges,” “The English Humourists,” and in
the “Roundabout Papers.” He was like Lowell: as a scholastic critic he
was far from infallible, but as a vital interpreter he seldom missed
the mark.
After all, the essential thing in life for us as real men is to have a
knowledge of facts to correct our follies, an ideal to guide our
efforts, and a gospel to sustain our hopes.
That was Thackeray’s message as moralist. It is expressed in the
last paragraph of his essay “Nil Nisi Bonum,” written just after the
death of Macaulay and Washington Irving:
“If any young man of letters reads this little sermon—and to him,
indeed, it is addressed—I would say to him, ‘Bear Scott’s words in
your mind, and be good, my dear.’ Here are two literary men gone
to their account, and, laus Deo, as far as we know, it is fair, and
open, and clean. Here is no need of apologies for shortcomings, or
explanations of vices which would have been virtues but for
unavoidable, etc. Here are two examples of men most differently
gifted—each pursuing his calling; each speaking his truth as God
bade him; each honest in his life; just and irreproachable in his
dealings; dear to his friends; honoured by his country; beloved at his
fireside. It has been the fortunate lot of both to give incalculable
happiness and delight to the world, which thanks them in return
with an immense kindliness, respect, affection. It may not be our
chance, brother scribe, to be endowed with such merit, or rewarded
with such fame. But the rewards of these men are rewards paid to
our service. We may not win the bâton or epaulettes; but God give
us strength to guard the honour of the flag!”
With this supplication for myself and for others, I leave this essay
on Thackeray, the greatest of English novelists, to the consideration
of real men.
GEORGE ELIOT AND REAL WOMEN
George Eliot was a woman who wrote full-grown novels for men.
Other women have done and are doing notable work in prose
fiction—Jane Austen, George Sand, Charlotte Brontë, Mrs. Stowe,
Margaret Deland, Edith Wharton, Katharine Fullerton Gerould, Mrs.
Humphry Ward—the list might easily be extended, but it would delay
us from the purpose of this chapter. Let me rather make a general
salute to all the sisterhood who have risen above the indignity of
being called “authoresses,” and, without pursuing perilous
comparisons, go directly to the subject in hand.
What was it that enabled George Eliot to enter the field of the
English novel at a time when Dickens and Thackeray were at the
height of their fame, and win a place in the same class with them?
It was certainly not the hide-and-seek of the sex of the new writer
under a pseudonym. You remember, opinions were divided on this
question. Carlyle and Thackeray thought that the author of Scenes
of Clerical Life was a man. Dickens was sure that it was a woman.
But a mystification of this kind has no interest apart from the
primary value of the works of the unidentified writer in question. Nor
does it last long as an advertisement, unless the following books
excel the first; and, in that case, the secret is sure to be soon
discovered.
George Eliot’s success and distinction as a novelist were due to
three things: first, the preliminary and rather obvious advantage of
having genius; second, a method of thinking and writing which is
commonly (though perhaps arrogantly) called masculine; third, a
quickness of insight into certain things, a warmth of sympathy for
suffering, and an instinct of sacrifice which we still regard (we hope
rightly) as feminine. A man for logic, a woman for feeling, a genius
for creative power—that was a great alliance. But the womanhood
kept the priority without which it would not only have died out, but
also have endangered, in dying, the other qualities. Dickens was
right when he said of certain touches in the work of this
pseudonymous writer: “If they originated with no woman, I believe
that no man ever before had the art of making himself mentally so
like a woman since the world began.”
George Eliot’s profile resembled Savonarola’s. He was one of her
heroes. But she was not his brother. She was his sister in the spirit.
Her essential femininity was the reason why the drawing of her
women surpassed the drawing of her men. It was more intimate,
more revealing, more convincing. She knew women better. She
painted them of many types and classes—from the peasant maid to
the well-born lady, from the selfish white cat to the generous white
swan-sister; from the narrow-minded Rosamund to the deep-
hearted, broad-minded Romola; all types, I think, but one—the
lewdly carnal Circe. In all her books, with perhaps a single
exception, it is a woman who stands out most clearly from the
carefully studied and often complex background as the figure of
interest. And even in that one it is the slight form of Eppie, the
golden-hearted girl who was sent to save old Silas Marner from
melancholy madness, that shines brightest in the picture.
The finest of her women—finest not in the sense of being
faultless, but of having in them most of that wonderful sacrificial
quality which Goethe called das ewig Weibliche—were those upon
whose spiritual portraits George Eliot spent her most loving care and
her most graphic skill.
She shows them almost always in the revealing light of love. But
she does not dwell meticulously on the symptoms or the course of
the merely physical attraction. She knows that it is there; she
confesses that it is potent. But it seems to her, (as indeed it really
is,) far more uniform and less interesting than the meaning of love in
the soul of a woman as daughter, sister, sweetheart, wife. Were it
not for that inward significance there would be little to differentiate
the physical act from the mating of the lower animals—an affair so
common and casual that it merits less attention than some writers
give it. But in the inner life of thought and emotion, in a woman’s
intellectual and moral nature,—there love has its mystery and its
power, there it brings deepest joy or sharpest sorrow, there it
strengthens or maims.
It is because George Eliot knows this and reveals it with
extraordinary clearness that her books have an especial value. Other
qualities they have, of course, and very high qualities. But this is
their proper and peculiar excellence, and the source, if I mistake
not, of their strongest appeal to sanely thinking men.
The Man Who Understood Woman is the title of a recent clever
trivial story. But of course such a man is a myth, an impostor, or a
self-deluder. He makes a preposterous claim.
Thackeray and Dickens, for example, made no such pretension.
Some of their women are admirably drawn; they are very lovable, or
very despicable, as the case may be; but they are not completely
convincing. Thackeray comes nearer than Dickens, and George
Meredith, I think, much nearer than either of the others. But in
George Eliot we feel that we are listening to one who does
understand. Her women, in their different types, reveal something of
that thinking, willing, feeling other-half of humanity with whom man
makes the journey of life. They do not cover all the possibilities of
variation in the feminine, for these are infinite, but they are real
women, and so they have an interest for real men.
Let us take it for granted that we know enough of the details of
George Eliot’s life to enable us to understand and appreciate certain
things in her novels. Such biographical knowledge is illuminating in
the study of the works of any writer. The author of a book is not an
algebraic quantity nor a strange monster, but a human being with
certain features and a certain life-history.
But, after all, the promotion of literary analysis is not the object of
these chapters. Plain reading, and the pleasure of it, is what I have
in mind. For that cause I love most of George Eliot’s novels, and am
ready to maintain that they are worthy to be loved. And so, even if
my “taken for granted” a few lines above should not be altogether
accurate in these days of ignorant contempt of all that is “Victorian,”
I may still go ahead to speak of her books as they are in themselves:
strong, fine, rewarding pieces of English fiction: that is what they
would remain, no matter who had written them.
It must be admitted at once that they are not adapted to readers
who like to be spared the trouble of thinking while they read. They
do not belong to the class of massage-fiction, Turkish-bath novels.
They require a certain amount of intellectual exercise; and for this
they return, it seems to me, an adequate recompense in the
pleasurable sense of quickened mental activity and vigour.
But this admission must not be taken to imply that they are
obscure, intricate, enigmatical, “tough reading,” like the later books
of George Meredith and Henry James, in which a minimum of
meaning is hidden in a maximum of obfuscated verbiage, and the
reader is invited to a tedious game of hunt-the-slipper. On the
contrary, George Eliot at her best is a very clear writer—decidedly
not shallow, nor superficial, nor hasty,—like the running comment
which is supposed to illuminate the scenes in a moving-picture show,
—but intentionally lucid and perspicuous. Having a story to tell, she
takes pains to tell it so that you can follow it, not only in its outward,
but also in its inward movement. Having certain characters to depict
(and almost always mixed characters of good and evil mingled and
conflicting as in real life), she is careful to draw them so that you
shall feel their reality and take an interest in their strifes and
adventures.
They are distinctly persons, capable of making their own choice
between the worse and the better reason, and thereafter influenced
by the consequences of that choice, which, if repeated, becomes a
habit of moral victory or defeat. They are not puppets in, the hands
of an inscrutable Fate, like most of the figures in the books of the
modern Russian novelists and their imitators. What do I care for the
ever-so realistically painted marionettes in the fiction of Messrs.
Gawky, Popoff, Dropoff, and Slumpoff? What interest have I in the
minute articulations of the dingy automatons of Mijnheer Couperus,
or the dismal, despicable figures who are pulled through the pages
of Mr. Samuel Butler’s The Way of All Flesh? A claim on compassion
they might have if they were alive. But being, by the avowal of their
creators, nothing more than imaginary bundles of sensation, helpless
playthings of irresistible hereditary impulse and entangling destiny,
their story and their fate leave me cold. What does it matter what
becomes of them? They can neither be saved nor damned. They can
only be drifted. There is no more human interest in them than there
is in the predestined saints and foredoomed sinners of a certain type
of Calvinistic theology.
But this is not George Eliot’s view of life. It is not to her “a tale
told by an idiot, full of sound and fury signifying nothing.” Within the
fixed circle of its stern natural and moral laws there is a hidden field
of conflict where the soul is free to discern and choose its own
cause, and to fight for it or betray it. However small that field may
be, while it exists life has a meaning, and personalities are real, and
the results of their striving or surrendering, though rarely seen
complete or final, are worth following and thinking about. Thus
George Eliot’s people—at least the majority of them—have the
human touch which justifies narrative and comment. We follow the
fortunes of Dinah Morris and of Maggie Tulliver, of Romola, and of
Dorothea Brooke—yes, and of Hetty Sorrel and Rosamund Vincy—
precisely because we feel that they are real women and that the
turning of their ways will reveal the secret of their hearts.
It is a mistake to think (as a recent admirable essay of Professor
W. L. Cross seems to imply) that the books of George Eliot are
characteristically novels of argument or propaganda. Once only, or
perhaps twice, she yielded to that temptation and spoiled her story.
But for the rest she kept clear of the snare of Tendenz.
Purpose-novels, like advertisements, belong in the temporary
department. As certain goods and wares go out of date, and the
often eloquent announcements that commended them suddenly
disappear; even so the “burning questions” of the hour and age burn
out, and the solutions of them presented in the form of fiction fall
down with the other ashes. They have served their purpose, well or
ill, and their transient importance is ended. What endures, if
anything, is the human story vividly told, the human characters
graphically depicted. These have a permanent value. These belong
to literature. Here I would place Adam Bede and Silas Marner and
The Mill on the Floss and Middlemarch, because they deal with
problems which never grow old; but not Robert Elsmere, because it
deals chiefly with a defunct controversy in Biblical criticism.
George Eliot was thirty-eight years old when she made the
amazing discovery that she was by nature, not what she had
thought herself, a philosophical essayist and a translator of arid
German treatises against revealed religion, but something very
different—a novelist of human souls, and especially of the souls of
women. It was the noteworthy success of her three long short
stories, Amos Barton, Mr. Gilfil’s Love Story, and Janet’s Repentance,
printed in Blackwood’s Magazine in 1857, that revealed her to herself
and to the world.
“Depend upon it, [she says to her imaginary reader in the first of
these stories,] you would gain unspeakably if you would learn with
me to see something of the poetry and the pathos, the tragedy and
the comedy, lying in the experience of the human soul that looks out
through dull gray eyes and speaks in a voice of quite ordinary
tones.”
It was the interior drama of human life that attracted her interest
and moved her heart with pity and fear, laughter and love. She
found it for the most part in what we should call mediocre
surroundings and on rather a humble and obscure stage. But what
she found was not mediocre. It was the same discovery that
Wordsworth made:
“A grandeur in the beatings of the heart.”
By this I do not mean to say that a close study of the humanness
of human nature, a searching contemplation of character, an acute
and penetrating psychological analysis is all that there is in her
novels. This is her predominant interest, beyond a doubt. She
belongs to the school of Hawthorne, Henry James, Thomas Hardy—
realists or romancers of the interior life. But she has other interests;
and there are other things to reward us in the reading of her books.
There is, first of all, an admirable skill in the setting of her stories.
No other novelist has described English midland landscape, towns,
and hamlets, better than she. No other writer has given the rich,
history-saturated scenery of Florence as well.
She is careful also not to exclude from her stage that messenger
of relief and contrast whom George Meredith calls “the comic spirit.”
Shakespeare’s clowns, wonderful as some of them are, seem at
times like supernumeraries. They come in to make a “diversion.” But
George Eliot’s rustic wits and conscious or unconscious humourists
belong to the story. Mrs. Poyser and Bartle Massey, Mrs. Glegg and
Mrs. Tulliver and Bob Jakin, could not be spared.
And then, her stories are really stories. They have action. They
move; though sometimes, it must be confessed, they move slowly.
Not only do the characters develop, one way or the other, but the
plot also develops. Sometimes it is very simple, as in Silas Marner;
sometimes it is extremely complicated, as in Middlemarch, where
three love-stories are braided together. One thing it never is—
theatrical. Yet at times it moves into an intense scene, like the trial
of Hetty Sorrel or the death of Tito Melema, in which the very
essence of tragedy is concentrated.
From the success of Scenes of Clerical Life George Eliot went on
steadily with her work in fiction, never turning aside, never pausing
even, except when her health compelled, or when she needed time
to fill her mind and heart with a new subject. She did not write
rapidly, nor are her books easy to read in a hurry.
It was an extraordinary series: Adam Bede in 1859, The Mill on
the Floss in 1860, Silas Marner in 1861, Romola in 1863, Felix Holt,
the Radical in 1866, Middlemarch in 1871, Daniel Deronda in 1876;
no padding, no “seconds,” each book apparently more successful,
certainly more famous, than its predecessor. How could one woman
produce so much closely wrought, finely finished work? Of what
sturdy mental race were the serious readers who welcomed it and
found delight in it?
Mr. Oscar Browning of Cambridge said that Daniel Deronda was
the climax, “the sun and glory of George Eliot’s art.” From that
academic judgment I venture to dissent. It is a great book, no
doubt, the work of a powerful intellect. But to me it was at the first
reading, and is still, a tiresome book. Tediousness, which is a totally
different thing from seriousness, is the unpardonable defect in a
novel. It may be my own fault, but Deronda seems to me something
of a prig. Now a man may be a prig without sin, but he ought not to
take up too much room. Deronda takes up too much room. And
Gwendolen Harleth, who dressed by preference in sea-green, seems
to me to have a soul of the same colour—a psychological mermaid.
She is unconvincing. I cannot love her. The vivid little Jewess, Mirah,
is the only character with charm in the book.
Middlemarch is noteworthy for its extraordinary richness of human
observation and the unexcelled truthfulness of some of its portraits.
Mr. Isaac Casaubon is the living image of the gray-minded scholar
and gentleman,—as delicately drawn as one of Miss Cecelia Beaux’
portraits of aged, learned, wrinkled men. Rosamund Vincy is the
typical “daughter of the horse-leech” in respectable clothes and
surroundings. Dorothea Brooke is one of George Eliot’s finest
sacrificial heroines:
“A perfect woman, nobly plann’d.”
The book, as a whole, seems to me to have the defect of
superabundance. There is too much of it. It is like one of the late
William Frith’s large canvases, “The Derby Day,” or “The Railway
Station.” It is constructed with skill, and full of rich material, but it
does not compose. You cannot see the people for the crowd. Yet
there is hardly a corner of the story in which you will not find
something worth while.
Felix Holt, the Radical is marred, at least for me, by a fault of
another kind. It is a novel of problem, of purpose. I do not care for
problem-novels, unless the problem is alive, and even then I do not
care very much for political economy in that form. It is too easy for
the author to prove any proposition by attaching it to a noble
character, or to disprove any theory by giving it an unworthy
advocate. English radicalism of 1832 has quite passed away, or gone
into the Coalition Cabinet. All that saves Felix Holt now (as it seems
to me, who read novels primarily for pleasure) is the lovely figure of
Esther Lyon, and her old father, a preacher who really was good.
Following the path still backward, we come to something
altogether different. Romola is a historical romance on the grand
scale. In the central background is the heroic figure of Savonarola,
saintly but not impeccable; in the middle distance, a crowd of
Renaissance people immersed in the rich and bloody turmoil of that
age; in the foreground, the sharp contrast of two epic personalities—
Tito Melema, the incarnation of smooth, easy-going selfishness
which never refuses a pleasure nor accepts a duty; and Romola, the
splendid embodiment of pure love in self-surrendering womanhood.
The shameful end of Tito, swept away by the flooded river Arno and
finally choked to death by the father whom he had disowned and
wronged, has in it the sombre tone of Fate. But the end of the book
is not defeat; it is triumph. Romola, victor through selfless courage
and patience, saves and protects the deserted mistress and children
of her faithless husband. In the epilogue we see her like Notre Dame
de Secours, throned in mercy and crowned with compassion.
Listen to her as she talks to Tito’s son in the loggia looking over
Florence to the heights beyond Fiesole.
“‘What is it, Lillo?’ said Romola, pulling his hair back from his
brow. Lillo was a handsome lad, but his features were turning out to
be more massive and less regular than his father’s. The blood of the
Tuscan peasant was in his veins.
“‘Mamma Romola, what am I to be?’ he said, well contented that
there was a prospect of talking till it would be too late to con Spirto
gentil any longer.
“‘What should you like to be, Lillo? You might be a scholar. My
father was a scholar, you know, and taught me a great deal. That is
the reason why I can teach you.’
“‘Yes,’ said Lillo, rather hesitatingly. ‘But he is old and blind in the
picture. Did he get a great deal of glory?’
“‘Not much, Lillo. The world was not always very kind to him, and
he saw meaner men than himself put into higher places, because
they could flatter and say what was false. And then his dear son
thought it right to leave him and become a monk; and after that, my
father, being blind and lonely, felt unable to do the things that would
have made his learning of greater use to men, so that he might still
have lived in his works after he was in his grave.’
“‘I should not like that sort of life,’ said Lillo. ‘I should like to be
something that would make me a great man, and very happy
besides—something that would not hinder me from having a good
deal of pleasure.’
“‘That is not easy, my Lillo. It is only a poor sort of happiness that
could ever come by caring very much about our own narrow
pleasures. We can only have the highest happiness, such as goes
along with being a great man, by having wide thoughts, and feeling
for the rest of the world as well as ourselves; and this sort of
happiness often brings so much pain with it, that we can only tell it
from pain by its being what we would choose before everything else,
because our souls see it is good. There are so many things wrong
and difficult in the world, that no man can be great—he can hardly
keep himself from wickedness—unless he gives up thinking much
about pleasure or rewards, and gets strength to endure what is hard
and painful. My father had the greatness that belongs to integrity;
he chose poverty and obscurity rather than falsehood. And there was
Fra Girolamo—you know why I keep to-morrow sacred: he had the
greatness which belongs to a life spent in struggling against
powerful wrong, and in trying to raise men to the highest deeds they
are capable of. And so, my Lillo, if you mean to act nobly and seek
to know the best things God has put within reach of men, you must
learn to fix your mind on that end, and not on what will happen to
you because of it. And remember, if you were to choose something
lower, and make it the rule of your life to seek your own pleasure
and escape from what is disagreeable, calamity might come just the
same; and it would be calamity falling on a base mind, which is the
one form of sorrow that has no balm in it, and that may well make a
man say, “It would have been better for me if I had never been
born.” I will tell you something, Lillo.’
“Romola paused for a moment. She had taken Lillo’s cheeks
between her hands, and his young eyes were meeting hers.
“‘There was a man to whom I was very near, so that I could see a
great deal of his life, who made almost every one fond of him, for he
was young, and clever, and beautiful, and his manners to all were
gentle and kind. I believe, when I first knew him, he never thought
of anything cruel or base. But because he tried to slip away from
everything that was unpleasant, and cared for nothing else so much
as his own safety, he came at last to commit some of the basest
deeds—such as make men infamous. He denied his father, and left
him to misery; he betrayed every trust that was reposed in him, that
he might keep himself safe and get rich and prosperous. Yet
calamity overtook him.’
“Again Romola paused. Her voice was unsteady, and Lillo was
looking up at her with awed wonder.
“‘Another time, my Lillo—I will tell you another time. See, there
are our old Piero di Cosimo and Nello coming up the Borgo Pinti,
bringing us their flowers. Let us go and wave our hands to them,
that they may know we see them.’”
Hardly one of George Eliot’s stories has a conventional “happy
ending.” Yet they leave us not depressed, but strengthened to
endure and invigorated to endeavour. In this they differ absolutely
from the pessimistic novels of the present hour, which not only leave
a bad taste in the mouth, but also a sense of futility in the heart.
Let me turn now to her first two novels, which still seem to me her
best. Bear in mind, I am not formulating academic theories, nor
pronouncing ex cathedrâ judgments, but simply recording for the
consideration of other readers certain personal observations and
reactions.
Adam Bede is a novel of rustic tragedy in which some of the
characters are drawn directly from memory. Adam is a partial
portrait of George Eliot’s father, and Dinah Morris a sketch of her
aunt, a Methodist woman preacher. There is plenty of comic relief in
the story, admirably done. Take the tongue duel between Bartle
Massey, the sharp-spoken, kind-hearted bachelor school-master, and
Mrs. Poyser, the humorous, pungent, motherly wife of the old farmer.
“‘What!’ said Bartle, with an air of disgust. ‘Was there a woman
concerned? Then I give you up, Adam.’
“‘But it’s a woman you’n spoke well on, Bartle,’ said Mr. Poyser.
‘Come, now, you canna draw back; you said once as women
wouldna ha’ been a bad invention if they’d all been like Dinah.’
“‘I meant her voice, man—I meant her voice, that was all,’ said
Bartle. ‘I can bear to hear her speak without wanting to put wool in
my ears. As for other things, I dare say she’s like the rest o’ the
women—thinks two and two ’ull come to make five, if she cries and
bothers enough about it.’
“‘Ay, ay!’ said Mrs. Poyser; ‘one ’ud think, an’ hear some folks talk,
as the men war ’cute enough to count the corns in a bag o’ wheat
wi’ only smelling at it. They can see through a barn door, they can.
Perhaps that’s the reason they can see so little o’ this side on’t.’
“‘Ah!’ said Bartle, sneeringly, ‘the women are quick enough—
they’re quick enough. They know the rights of a story before they
hear it, and can tell a man what his thoughts are before he knows
’em himself.’
“‘Like enough,’ said Mrs. Poyser; ‘for the men are mostly so slow,
their thoughts overrun ’em, an’ they can only catch ’em by the tail. I
can count a stocking-top while a man’s getting’s tongue ready; an’
when he outs wi’ his speech at last, there’s little broth to be made
on’t. It’s your dead chicks take the longest hatchin’. Howiver, I’m not
denyin’ the women are foolish: God Almighty made ’em to match the
men.’
“‘Match!’ said Bartle; ‘ay, as vinegar matches one’s teeth. If a man
says a word, his wife’ll match it with a contradiction; if he’s a mind
for hot meat, his wife’ll match it with cold bacon; if he laughs, she’ll
match him with whimpering. She’s such a match as the horsefly is to
th’ horse: she’s got the right venom to sting him with—the right
venom to sting him with.’
“‘What dost say to that?’ said Mr. Poyser, throwing himself back
and looking merrily at his wife.
“‘Say!’ answered Mrs. Poyser, with dangerous fire kindling in her
eye; ‘why, I say as some folks’ tongues are like the clocks as run on
strikin’, not to tell you the time o’ the day, but because there’s
summat wrong i’ their own inside.’ ...”
The plot, as in Scott’s Heart of Midlothian, turns on a case of
seduction and child murder, and the contrast between Effie and
Jeannie Deans has its parallel in the stronger contrast between Hetty
Sorrel and Dinah Morris. Hetty looked as if she were “made of
roses”; but she was, in Mrs. Poyser’s phrase, “no better nor a cherry
wi’ a hard stone inside it.” Dinah’s human beauty of face and voice
was the true reflection of her inward life which
“cast a beam on the outward shape,
The unpolluted temple of the mind,
And turned it by degrees to the soul’s essence.”
The crisis of the book comes in the prison, where Dinah wrestles
for the soul of Hetty—a scene as passionate and moving as any in
fiction. Dinah triumphs, not by her own might, but by the sheer
power and beauty of the Christian faith and love which she
embodies.
In George Eliot’s novels you will find some passages of stinging
and well-merited satire on the semi-pagan, conventional religion of
middle-class orthodoxy in England of the nineteenth century—“proud
respectability in a gig of unfashionable build; worldliness without
side-dishes”—read the chapter on “A Variation of Protestantism
Unknown to Bossuet,” in The Mill on the Floss. But you will not find a
single page or paragraph that would draw or drive the reader away
from real Christianity. On the contrary, she has expressed the very
secret of its appeal to the human heart through the words and
conduct of some of her best characters. They do not argue; they
utter and show the meaning of religion. On me the effect of her
books is a deepened sense of the inevitable need of Christ and his
gospel to sustain and nourish the high morality of courage and
compassion, patience, and hope, which she so faithfully teaches.
The truth is, George Eliot lived in the afterglow of Christian faith.
Rare souls are capable of doing that. But mankind at large needs the
sunrise.
The Mill on the Floss is partly an autobiographic romance. Maggie
Tulliver’s character resembles George Eliot in her youth. The contrast
between the practical and the ideal, the conflict between love and
duty in the heart of a girl, belong to those problematische Naturen,
as Goethe called them, which may taste keen joys but cannot
escape sharp sorrows. The centre of the story lies in Maggie’s strong
devotion to her father and to her brother Tom—a person not
altogether unlike the “elder brother” in the parable—in strife with her
love for Philip, the son of the family enemy. Tom ruthlessly
commands his sister to choose between breaking with him and
giving up her lover. Maggie, after a bitter struggle, chooses her
brother. Would a real woman do that? Yes, I have known some very
real women who have done it, in one case with a tragic result.
The original title of this book (and the right one) was Sister
Maggie. Yet we can see why George Eliot chose the other name. The
little river Floss, so tranquil in its regular tidal flow, yet capable of
such fierce and sudden outbreaks, runs through the book from
beginning to end. It is a mysterious type of the ineluctable power of
Nature in man’s mortal drama.
In the last chapter, when the flood comes, and the erring sister
who loved her brother so tenderly, rescues him who loved her so
cruelly from the ruined mill, the frail skiff which carries them clasped
heart to heart, reconciled in that revealing moment, goes down in
the senseless irresistible rush of waters.
It is not a “bad ending.” The sister’s love triumphs. Such a close
was inevitable for such a story. But it is not a conclusion. It cries out
for immortality.
On the art of George Eliot judgments have differed. Mr. Oscar
Browning, a respectable authority, thinks highly of it. Mr. W. C.
Brownell, a far better critic, indeed one of the very best, thinks less
favourably of it, says that it is too intellectual; that the development
and conduct of her characters are too logical and consistent; that
the element of surprize, which is always present in life, is lacking in
her people. “Our attention,” he writes, “is so concentrated on what
they think that we hardly know how they feel, or whether ... they
feel at all.” This criticism does not seem to me altogether just.
Certainly there is no lack of surprize in Maggie Tulliver’s temporary
infatuation with the handsome, light-minded Stephen Guest, or in
Dorothea Brooke’s marriage to that heady young butterfly, Will
Ladislaw. These things certainly were not arrived at by logical
consistency. Nor can one lay his hand on his heart and say that
there is no feeling in the chapter where the fugitive Romola comes
as Madonna to the mountain village, stricken by pestilence, or in the
passage where Dinah Morris strives for Hetty’s soul in prison.
George Eliot herself tells us the purpose of her art—it is verity.
“It is for this rare, precious quality of truthfulness that I delight in
many Dutch paintings, which lofty-minded people despise.... All
honour and reverence to the divine beauty of form! Let us cultivate
it to the utmost in men, women, and children—in our gardens and in
our homes. But let us love that other beauty, too, which lies in no
secret of proportion, but in the secret of deep human sympathy.”
It is Rembrandt, then, rather than Titian, who is her chosen
painter. But she does not often attain his marvellous chiaroscuro.
Her style is clear and almost always firm in drawing, though
deficient in colour. It is full of meaning, almost over-scrupulous in
defining precisely what she wishes to express. Here and there it
flashes into a wise saying, a sparkling epigram. At other times,
especially in her later books, it spreads out and becomes too diffuse,
too slow, like Sir Walter Scott’s. But it never repels by vulgar
smartness, nor perplexes by vagueness and artificial obscurity. It
serves her purpose well—to convey the results of her scrutiny of the
inner life and her loving observation of the outer life in its humblest
forms. In these respects it is admirable and satisfying. And it is her
own—she does not imitate, nor write according to a theory.
Her general view of human nature is not essentially different from
that expressed in a passage which I quoted from Thackeray in the
previous chapter. We are none of us “irreproachable characters.” We
are “mixed human beings.” Therefore she wishes to tell her stories
“in such a way as to call forth tolerant judgment, pity, and
sympathy.”
As I began so let me end this chapter—with a word on women.
For myself, I think it wise and prudent to maintain with Plutarch that
virtue in man and woman is one and the same. Yet there is a
difference between the feminine and the masculine virtues. This
opinion Plutarch sets forth and illustrates in his brief histories, and
George Eliot in her novels. But of the virtues of women she gives
more and finer examples.
THE POET OF IMMORTAL YOUTH
One of the things that surprized and bewildered old Colonel
Newcome when he gathered his boy’s friends around the mahogany
tree in the dull, respectable dining-room at 12 Fitzroy Square, was to
hear George Warrington declare, between huge puffs of tobacco
smoke, “that young Keats was a genius to be estimated in future
days with young Raphael.” At this Charles Honeyman sagely nodded
his ambrosial head, while Clive Newcome assented with sparkling
eyes. But to the Colonel, sitting kindly grave and silent at the head
of the table, and recalling (somewhat dimly) the bewigged and
powdered poetry of the age of Queen Anne, such a critical sentiment
seemed radical and revolutionary, almost ungentlemanly.
How astonished he would have been sixty years later if he had
taken up Mr. Sidney Colvin’s Life of Keats, in the “English Men of
Letters Series,” and read in the concluding chapter the deliberate
and remarkable judgment that “by power, as well as by
temperament and aim, he was the most Shakespearean spirit that
has lived since Shakespeare”!
In truth, from the beginning the poetry of Keats has been visited
too much by thunder-storms of praise. It was the indiscriminate
enthusiasm of his friends that drew out the equally indiscriminate
ridicule of his enemies. It was the premature salutation offered to
him as a supreme master of the most difficult of all arts that gave
point and sting to the criticism of evident defects in his work. The
Examiner hailed him, before his first volume had been printed, as
one who was destined to revive the early vigour of English poetry.
Blackwood’s Magazine retorted by quoting his feeblest lines and
calling him “Johnny Keats.” The suspicion of log-rolling led to its
usual result in a volley of stone-throwing.
Happily, the ultimate fame and influence of a true poet are not
determined by the partizan conflicts which are waged about his
name. He may suffer some personal loss by having to breathe, at
times, a perturbed atmosphere of mingled flattery and abuse instead
of the still air of delightful studies. He may be robbed of some days
of a life already far too short, by the pestilent noise and confusion
arising from that scramble for notoriety which is often unduly
honoured with the name of “literary activity.” And there are some
men whose days of real inspiration are so few, and whose poetic gift
is so slender, that this loss proves fatal to them. They are completely
carried away and absorbed by the speculations and strifes of the
market-place. They spend their time in the intrigues of rival poetic
enterprises, and learn to regard current quotations in the trade
journals as the only standard of value. Minor poets at the outset,
they are tempted to risk their little all on the stock exchange of
literature, and, losing their last title to the noun, retire to bankruptcy
on the adjective.
But Keats did not belong to this frail and foolish race. His lot was
cast in a world of petty conflict and ungenerous rivalry, but he was
not of that world. It hurt him a little, but it did not ruin him. His
spiritual capital was too large, and he regarded it as too sacred to be
imperilled by vain speculations. He had in Chaucer and Spenser,
Shakespeare and Chapman, Milton and Petrarch, older and wiser
friends than Leigh Hunt. For him
“The blue
Bared its eternal bosom, and the dew
Of summer nights collected still to make
The morning precious: beauty was awake!”
He perceived, by that light which comes only to high-souled and
noble-hearted poets,
“The great end
Of poesy, that it should be a friend
To soothe the cares and lift the thoughts of man.”
To that end he gave the best that he had to give, freely, generously,
joyously pouring himself into the ministry of his art. He did not
dream for a moment that the gift was perfect. Flattery could not
blind him to the limitations and defects of his early work. He was his
own best and clearest critic. But he knew that so far as it went his
poetic inspiration was true. He had faithfully followed the light of a
pure and elevating joy in the opulent, manifold beauty of nature and
in the eloquent significance of old-world legends, and he believed
that it had already led him to a place among the poets whose verse
would bring delight, in far-off years, to the sons and daughters of
mankind. He believed also that if he kept alive his faith in the truth
of beauty and the beauty of truth it would lead him on yet further,
into a nobler life and closer to those immortal bards whose
“Souls still speak
To mortals of their little week;
Of their sorrows and delights;
Of their passions and their spites;
Of their glory and their shame;
What doth strengthen and what maim.”
He expressed this faith very clearly in the early and uneven poem
called “Sleep and Poetry,” in a passage which begins
“Oh, for ten years, that I may overwhelm
Myself in poesy! so I may do the deed
That my own soul has to itself decreed.”
And then, ere four years had followed that brave wish, his voice fell
silent under a wasting agony of pain and love, and the daisies were
growing upon his Roman grave.
The pathos of his frustrated hope, his early death, has sometimes
blinded men a little, it seems to me, to the real significance of his
work and the true quality of his influence in poetry. He has been
lamented in the golden verse of Shelley’s “Adonaïs,” and in the prose
of a hundred writers who have shared Shelley’s error without
partaking of his genius, as the loveliest innocent ever martyred by
the cruelty of hostile critics. But, in fact, the vituperations of Gifford
and his crew were no more responsible for the death of Keats, than
the stings of insects are for the death of a man who has perished of
hunger on the coast of Labrador. They added to his sufferings, no
doubt, but they did not take away his life. Keats had far too much
virtue in the old Roman sense—far too much courage, to be killed by
a criticism. He died of consumption, as he clearly and sadly knew
that he was fated to do when he first saw the drop of arterial blood
upon his pillow.
Nor is it just, although it may seem generous, to estimate his
fame chiefly by the anticipation of what he might have accomplished
if he had lived longer; to praise him for his promise at the expense
of his performance; and to rest his claim to a place among the
English poets upon an uncertain prophecy of rivalry with
Shakespeare. I find a far sounder note in Lowell’s manly essay, when
he says: “No doubt there is something tropical and of strange
overgrowth in his sudden maturity, but it was maturity nevertheless.”
I hear the accent of a wiser and saner criticism in the sonnet of one
of our American poets:
“Touch not with dark regret his perfect fame,
Sighing, ‘Had he but lived he had done so’;
Or, ‘Were his heart not eaten out with woe
John Keats had won a prouder, mightier name!’
Take him for what he was and did—nor blame
Blind fate for all he suffered. Thou shouldst know
Souls such as his escape no mortal blow—
No agony of joy, or sorrow, or shame.”
“Take him for what he was and did”—that should be the key-note
of our thought of Keats as a poet. The exquisite harmony of his
actual work with his actual character; the truth of what he wrote to
what his young heart saw and felt and enjoyed; the simplicity of his
very exuberance of ornament, and the naturalness of his artifice; the
sincerity of his love of beauty and the beauty of his sincerity—these
are the qualities which give an individual and lasting charm to his
poetry, and make his gift to the world complete in itself and very
precious, although,—or perhaps we should even say because,—it
was unfinished.
Youth itself is imperfect: it is impulsive, visionary, and
unrestrained; full of tremulous delight in its sensations, but not yet
thoroughly awake to the deeper meanings of the world; avid of
novelty and mystery, but not yet fully capable of hearing or
interpreting the still, small voice of divine significance which
breathes from the simple and familiar elements of life.
Yet youth has its own completeness as a season of man’s
existence. It is justified and indispensable. Alfred de Musset’s
“We old men born yesterday”
are simply monstrous. The poetry which expresses and represents
youth, the poetry of sensation and sentiment, has its own place in
the literature of the world. This is the order to which the poetry of
Keats belongs.
He is not a feminine poet, as Mr. Coventry Patmore calls him, any
more than Theocritus or Tennyson is feminine; for the quality of
extreme sensitiveness to outward beauty is not a mark of femininity.
It is found in men more often and more clearly than in women. But
it is always most keen and joyous and overmastering in the morning
of the soul.
Keats is not a virile poet, like Dante or Shakespeare or Milton; that
he would have become one if he had lived is a happy and loving
guess. He is certainly not a member of the senile school of poetry,
which celebrates the impotent and morbid passions of decay, with a
café chantant for its temple, and the smoke of cigarettes for incense,
and cups of absinthe for its libations, and for its goddess not the
immortal Venus rising from the sea, but the weary, painted, and
decrepit Venus sinking into the gutter.
He is in the highest and best sense of the word a juvenile poet
—“mature,” as Lowell says, but mature, as genius always is, within
the boundaries and in the spirit of his own season of life. The very
sadness of his lovely odes, “To a Nightingale,” “On a Grecian Urn,”
“To Autumn,” “To Psyche,” is the pleasant melancholy of the
springtime of the heart. “The Eve of St. Agnes,” pure and
passionate, surprizing us by its fine excess of colour and melody,
sensuous in every line, yet free from the slightest taint of sensuality,
is unforgettable and unsurpassable as the dream of first love. The
poetry of Keats, small in bulk and slight in body as it seems at first
sight to be, endures, and will endure, in English literature, because it
is the embodiment of the spirit of immortal youth.
Here, I think, we touch its secret as an influence upon other
poets. For that it has been an influence,—in the older sense of the
word, which carries with it a reference to the guiding and controlling
force supposed to flow from the stars to the earth,—is beyond all
doubt. The History of English Literature, with which Taine amused us
some fifty years ago, nowhere displays its narrowness of vision more
egregiously than in its failure to take account of Gray, Collins, and
Keats as fashioners of English poetry. It does not mention Gray and
Collins at all; the name of Keats occurs only once, with a reference
to “sickly or overflowing imagination,” but to Byron nearly fifty pages
are devoted. The American critic, Stedman, showed a far broader
and more intelligent understanding of the subject when he said that
“Wordsworth begot the mind, and Keats the body, of the idyllic
Victorian School.”
We can trace the influence of Keats not merely in the conscious or
unconscious imitations of his manner, like those which are so evident
in the early poems of Tennyson and Procter, in Hood’s Plea of the
Midsummer Fairies and Lycus the Centaur, in Rossetti’s Ballads and
Sonnets, and William Morris’s Earthly Paradise, but also in the
youthful spirit of delight in the retelling of old tales of mythology and
chivalry; in the quickened sense of pleasure in the luxuriance and
abundance of natural beauty; in the freedom of overflowing
cadences transmuting ancient forms of verse into new and more
flexible measures; in the large liberty of imaginative diction, making
all nature sympathize with the joy and sorrow of man,—in brief, in
many of the finest marks of a renascence, a renewed youth, which
characterize the poetry of the early Victorian era.
I do not mean to say that Keats alone, or chiefly, was responsible
for this renascence. He never set up to lead a movement or to found
a school. His genius is not to be compared to that of a commanding
artist like Giotto or Leonardo or Michelangelo, but rather to that of a
painter like Botticelli, whose personal and expressive charm makes
itself felt in the work of many painters, who learned secrets of grace
and beauty from him, though they were not his professed disciples
or followers.
Take for example Matthew Arnold. He called himself, and no doubt
rightly, a Wordsworthian. But it was not from Wordsworth that he
caught the strange and searching melody of “The Forsaken
Merman,” or learned to embroider the laments for “Thyrsis” and
“The Scholar-Gypsy” with such opulence of varied bloom as makes
Welcome to Our Bookstore - The Ultimate Destination for Book Lovers
Are you passionate about books and eager to explore new worlds of
knowledge? At our website, we offer a vast collection of books that
cater to every interest and age group. From classic literature to
specialized publications, self-help books, and children’s stories, we
have it all! Each book is a gateway to new adventures, helping you
expand your knowledge and nourish your soul
Experience Convenient and Enjoyable Book Shopping Our website is more
than just an online bookstore—it’s a bridge connecting readers to the
timeless values of culture and wisdom. With a sleek and user-friendly
interface and a smart search system, you can find your favorite books
quickly and easily. Enjoy special promotions, fast home delivery, and
a seamless shopping experience that saves you time and enhances your
love for reading.
Let us accompany you on the journey of exploring knowledge and
personal growth!
ebookgate.com

More Related Content

Similar to Essential Windows Phone 7 5 Application Development with Silverlight 1st Edition Shawn Wildermuth (20)

PPTX
Windows phone app development overview
Alan Mendelevich
 
PPTX
Windows Phone Application development
vkalve
 
PPTX
WP7 HUB_Launch event WP7
MICTT Palma
 
PPTX
Windows Phone 7
Prashant Tiwari
 
PDF
Windows Phone 7 Programming for Fun and Profit
Chris Craft
 
PPTX
데브멘토 발표세미나
Seo Jinho
 
PPTX
Windows Phone 7 Unleashed Session 1
Wes Yanaga
 
PPTX
Presentation[1]
Palash Debnath
 
PPTX
Stc ftn-wp7-intro
Goran Djonovic
 
PPTX
WP7 HUB_Marketplace
MICTT Palma
 
PPTX
Windows phone
Rishabha Garg
 
PPTX
Windows 7 mobile
Pablo Alejandre del Rio
 
PPTX
WP7 Study 발표 - WinMoDev
Seo Jinho
 
PPTX
Nashua Cloud .NET User Group - Basic WP8 App Dev With XAML and C#, April 2013
John Garland
 
PPTX
Designing and developing a Windows Phone 7 Silverlight Application End-to-End...
Katrien De Graeve
 
PPTX
Windows Phone and Windows 8 application development
Christos Matskas
 
PDF
Windows Phone 7 Microsoft's Entrant to the Smartphone Wars
PointAbout - Mobile Application Strategy & Development
 
PPTX
Windows Phone Code Camp Montreal - The Windows Phone 7.5 opportunity
Frédéric Harper
 
PDF
QBS Visual Studio 2012 and modern windows apps
Lee Stott
 
PPTX
Windows Phone 8 App Development
DalpatTapaniya
 
Windows phone app development overview
Alan Mendelevich
 
Windows Phone Application development
vkalve
 
WP7 HUB_Launch event WP7
MICTT Palma
 
Windows Phone 7
Prashant Tiwari
 
Windows Phone 7 Programming for Fun and Profit
Chris Craft
 
데브멘토 발표세미나
Seo Jinho
 
Windows Phone 7 Unleashed Session 1
Wes Yanaga
 
Presentation[1]
Palash Debnath
 
Stc ftn-wp7-intro
Goran Djonovic
 
WP7 HUB_Marketplace
MICTT Palma
 
Windows phone
Rishabha Garg
 
Windows 7 mobile
Pablo Alejandre del Rio
 
WP7 Study 발표 - WinMoDev
Seo Jinho
 
Nashua Cloud .NET User Group - Basic WP8 App Dev With XAML and C#, April 2013
John Garland
 
Designing and developing a Windows Phone 7 Silverlight Application End-to-End...
Katrien De Graeve
 
Windows Phone and Windows 8 application development
Christos Matskas
 
Windows Phone 7 Microsoft's Entrant to the Smartphone Wars
PointAbout - Mobile Application Strategy & Development
 
Windows Phone Code Camp Montreal - The Windows Phone 7.5 opportunity
Frédéric Harper
 
QBS Visual Studio 2012 and modern windows apps
Lee Stott
 
Windows Phone 8 App Development
DalpatTapaniya
 

Recently uploaded (20)

PPTX
PATIENT ASSIGNMENTS AND NURSING CARE RESPONSIBILITIES.pptx
PRADEEP ABOTHU
 
PDF
Biological Bilingual Glossary Hindi and English Medium
World of Wisdom
 
PPTX
How to Manage Large Scrollbar in Odoo 18 POS
Celine George
 
PPTX
SPINA BIFIDA: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
PPTX
Growth and development and milestones, factors
BHUVANESHWARI BADIGER
 
PDF
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
PDF
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - GLOBAL SUCCESS - CẢ NĂM - NĂM 2024 (VOCABULARY, ...
Nguyen Thanh Tu Collection
 
PPT
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
PDF
Generative AI: it's STILL not a robot (CIJ Summer 2025)
Paul Bradshaw
 
PPTX
2025 Winter SWAYAM NPTEL & A Student.pptx
Utsav Yagnik
 
PPTX
How to Set Maximum Difference Odoo 18 POS
Celine George
 
PDF
The History of Phone Numbers in Stoke Newington by Billy Thomas
History of Stoke Newington
 
PPT
Talk on Critical Theory, Part II, Philosophy of Social Sciences
Soraj Hongladarom
 
PDF
LAW OF CONTRACT ( 5 YEAR LLB & UNITARY LLB)- MODULE-3 - LEARN THROUGH PICTURE
APARNA T SHAIL KUMAR
 
PDF
Knee Extensor Mechanism Injuries - Orthopedic Radiologic Imaging
Sean M. Fox
 
PDF
Stokey: A Jewish Village by Rachel Kolsky
History of Stoke Newington
 
PDF
0725.WHITEPAPER-UNIQUEWAYSOFPROTOTYPINGANDUXNOW.pdf
Thomas GIRARD, MA, CDP
 
PDF
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
PPTX
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
PDF
Lesson 2 - WATER,pH, BUFFERS, AND ACID-BASE.pdf
marvinnbustamante1
 
PATIENT ASSIGNMENTS AND NURSING CARE RESPONSIBILITIES.pptx
PRADEEP ABOTHU
 
Biological Bilingual Glossary Hindi and English Medium
World of Wisdom
 
How to Manage Large Scrollbar in Odoo 18 POS
Celine George
 
SPINA BIFIDA: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
Growth and development and milestones, factors
BHUVANESHWARI BADIGER
 
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - GLOBAL SUCCESS - CẢ NĂM - NĂM 2024 (VOCABULARY, ...
Nguyen Thanh Tu Collection
 
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
Generative AI: it's STILL not a robot (CIJ Summer 2025)
Paul Bradshaw
 
2025 Winter SWAYAM NPTEL & A Student.pptx
Utsav Yagnik
 
How to Set Maximum Difference Odoo 18 POS
Celine George
 
The History of Phone Numbers in Stoke Newington by Billy Thomas
History of Stoke Newington
 
Talk on Critical Theory, Part II, Philosophy of Social Sciences
Soraj Hongladarom
 
LAW OF CONTRACT ( 5 YEAR LLB & UNITARY LLB)- MODULE-3 - LEARN THROUGH PICTURE
APARNA T SHAIL KUMAR
 
Knee Extensor Mechanism Injuries - Orthopedic Radiologic Imaging
Sean M. Fox
 
Stokey: A Jewish Village by Rachel Kolsky
History of Stoke Newington
 
0725.WHITEPAPER-UNIQUEWAYSOFPROTOTYPINGANDUXNOW.pdf
Thomas GIRARD, MA, CDP
 
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
Lesson 2 - WATER,pH, BUFFERS, AND ACID-BASE.pdf
marvinnbustamante1
 
Ad

Essential Windows Phone 7 5 Application Development with Silverlight 1st Edition Shawn Wildermuth

  • 1. Essential Windows Phone 7 5 Application Development with Silverlight 1st Edition Shawn Wildermuth download https://ebookgate.com/product/essential-windows- phone-7-5-application-development-with-silverlight-1st-edition- shawn-wildermuth/ Get Instant Ebook Downloads – Browse at https://ebookgate.com
  • 2. Get Your Digital Files Instantly: PDF, ePub, MOBI and More Quick Digital Downloads: PDF, ePub, MOBI and Other Formats Windows Phone 7 Developer Guide Building connected mobile applications with Microsoft Silverlight Developer Series 1st Edition Dominic Betts https://ebookgate.com/product/windows-phone-7-developer-guide- building-connected-mobile-applications-with-microsoft- silverlight-developer-series-1st-edition-dominic-betts/ Windows Phone 7 Secrets 1st Edition Paul Thurrott https://ebookgate.com/product/windows-phone-7-secrets-1st- edition-paul-thurrott/ Programming with Mobile Applications Android iOS and Windows Phone 7 1st Edition Thomas J. Duffy https://ebookgate.com/product/programming-with-mobile- applications-android-ios-and-windows-phone-7-1st-edition-thomas- j-duffy/ Windows 8 and Windows Phone 8 Game Development 1st Edition Adam Dawes (Auth.) https://ebookgate.com/product/windows-8-and-windows-phone-8-game- development-1st-edition-adam-dawes-auth/
  • 3. Professional Windows Phone 7 Game Development Creating Games using XNA Game Studio 4 1st Edition Chris G. Williams https://ebookgate.com/product/professional-windows-phone-7-game- development-creating-games-using-xna-game-studio-4-1st-edition- chris-g-williams/ Pro Windows Phone App Development 3rd Edition Falafel Software https://ebookgate.com/product/pro-windows-phone-app- development-3rd-edition-falafel-software/ Windows Phone 7 Recipes A Problem Solution Approach 1st Edition Fabio Claudio Ferracchiati https://ebookgate.com/product/windows-phone-7-recipes-a-problem- solution-approach-1st-edition-fabio-claudio-ferracchiati/ Microsoft Silverlight 4 Business Application Development Beginners Guide 1st New edition Edition Cameron Albert https://ebookgate.com/product/microsoft-silverlight-4-business- application-development-beginners-guide-1st-new-edition-edition- cameron-albert/ Windows 7 Secrets 1st Edition Paul Thurrott https://ebookgate.com/product/windows-7-secrets-1st-edition-paul- thurrott/
  • 6. The award-winning Microsoft .NET Development Series was established in 2002 to provide professional developers with the most comprehensive, practical coverage of the latest .NET technologies. Authors in this series include Microsoft architects, MVPs, and other experts and leaders in the field of Microsoft development technologies. Each book provides developers with the vital information and critical insight they need to write highly effective applications. Visit informit.com/msdotnetseries for a complete list of available products. Microsoft ® .NET Development Series
  • 7. Essential Windows Phone 7.5 Application Development with Silverlight Shawn Wildermuth Upper Saddle River, NJ • Boston • Indianapolis • San Francisco New York • Toronto • Montreal • London • Munich • Paris • Madrid Capetown • Sydney • Tokyo • Singapore • Mexico City
  • 8. Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and the publisher was aware of a trademark claim, the designations have been printed with initial capital letters or in all capitals. The .NET logo is either a registered trademark or trademark of Microsoft Corporation in the United States and/or other countries and is used under license from Microsoft. Microsoft, Windows, Visual Basic, Visual C#, and Visual C++ are either registered trademarks or trademarks of Microsoft Corporation in the U.S.A. and/or other countries/regions. The author and publisher have taken care in the preparation of this book, but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for incidental or consequential damages in connection with or arising out of the use of the information or programs contained herein. The publisher offers excellent discounts on this book when ordered in quantity for bulk purchases or special sales, which may include electronic versions and/or custom covers and content particular to your business, training goals, marketing focus, and branding interests. For more information, please contact: U.S. Corporate and Government Sales (800) 382-3419 [email protected] For sales outside the United States, please contact: International Sales [email protected] Visit us on the Web: informit.com/aw Library of Congress Cataloging-in-Publication Data Wildermuth, Shawn. Essential windows phone 7.5 : application development with silverlight / Shawn Wildermuth. p. cm. Includes index. ISBN 978-0-321-75213-0 (pbk. : alk. paper) 1. Windows phone (Computer file) 2. Silverlight (Electronic resource) 3. Operating systems (Computers) 4. Application software—Development. 5. Mobile computing—Programming. I. Title. QA76.59.W54 2012 005.4’46—dc23 2011036842 Copyright © 2012 Pearson Education, Inc. All rights reserved. Printed in the United States of America. This publication is protected by copy- right, and permission must be obtained from the publisher prior to any prohibited reproduction, storage in a retrieval system, or transmission in any form or by any means, electronic, mechanical, photocopying, recording, or likewise. To obtain permission to use material from this work, please submit a written request to Pearson Education, Inc., Permissions Department, One Lake Street, Upper Saddle River, New Jersey 07458, or you may fax your request to (201) 236-3290. ISBN-13: 978-0-321-75213-0 ISBN-10: 0-321-75213-9 Text printed in the United States on recycled paper at RR Donnelley in Crawfordsville, Indiana. First printing, December 2011
  • 9. To my friend and mentor, Chris Sells, without whom I would have never learned that the story is more important than the facts.
  • 11. vii Contents at a Glance Figures xvii Tables xxv Foreword xxvii Preface xxix Acknowledgments xxxi About the Author xxxiii 1 Introducing Windows Phone 1 2 Writing Your First Phone Application 25 3 XAML Overview 61 4 Controls 89 5 Designing for the Phone 139 6 Developing for the Phone 187 7 Phone Integration 219 8 Databases and Storage 305 9 Multitasking 337 10 Services 369 11 The Marketplace 431 Index 459
  • 13. ix Contents Figures xvii Tables xxv Foreword xxvii Preface xxix Acknowledgments xxxi About the Author xxxiii 1 Introducing Windows Phone 1 A Different Kind of Phone 1 Integrated Experiences 6 Phone Specifications 7 Input Patterns 9 Designing for Touch 10 Hardware Buttons 11 Keyboards 11 Sensors 13 Application Lifecycle 14 Driving Your Development with Services 15 Live Tiles 16 The Marketplace 18 Distributing Your Application through the Marketplace 18 Marketplace Submissions 19 Application Policies 20
  • 14. x Contents Content Policies 23 Where Are We? 24 2 Writing Your First Phone Application 25 Preparing Your Machine 25 Creating a New Project 27 Visual Studio 27 XAML 32 Designing with Blend 36 Adding Code 43 Working with Events 46 Debugging in the Emulator 47 Debugging with a Device 48 Using Touch 52 Working with the Phone 55 Where Are We? 59 3 XAML Overview 61 What Is XAML? 61 XAML Object Properties 63 Understanding XAML Namespaces 64 Naming in XAML 65 Visual Containers 66 Visual Grammar 70 Shapes 71 Brushes 72 Colors 73 Text 74 Images 75 Transformations and Animations 77 Transformations 77 Animations 80 XAML Styling 82 Understanding Resources 83 Understanding Styles 84 Where Are We? 87
  • 15. xi Contents 4 Controls 89 Controls in Silverlight 89 Simple Controls 91 Content Controls 97 List Controls 98 Phone-Specific Controls 99 Panorama Control 99 Pivot Control 102 Data Binding 105 Simple Data Binding 105 Using a DataTemplate 108 Improving Scrolling Performance 108 Binding Formatting 110 Element Binding 110 Converters 111 Data Binding Errors 113 Control Templates 114 Silverlight for Windows Phone Toolkit 119 AutoCompleteBox Control 119 ContextMenu Control 121 DatePicker and TimePicker Controls 122 ListPicker Control 124 LongListSelector Control 127 PerformanceProgressBar Control 131 ToggleSwitch Control 132 ExpanderView Control 133 PhoneTextBox Control 134 WrapPanel Layout Container 136 Where Are We? 138 5 Designing for the Phone 139 The Third Screen 139 It Is a Phone, Right? 143 Deciding on an Application Paradigm 144 Panorama 146
  • 16. xii Contents Pivot 147 Simple Pages 150 Microsoft Expression Blend 150 Creating a Project 150 A Tour around Blend 151 Blend Basics 159 Layout 159 Brushes 164 Creating Animations 169 Working with Behaviors 173 Phone-Specific Design 176 The ApplicationBar in Blend 176 Using the Panorama Control in Blend 179 Using the Pivot Control in Blend 182 Previewing Applications 185 Where Are We? 185 6 Developing for the Phone 187 Application Lifecycle 187 Navigation 190 Tombstoning 195 The Phone Experience 200 Orientation 201 Designing for Touch 203 Application Client Area 211 Application Bar 213 Understanding Idle Detection 215 The Tilt Effect 216 Where Are We? 218 7 Phone Integration 219 Using Vibration 219 Using Motion 220 Emulating Motion 223 Using Sound 226 Playing Sounds with MediaElement 226
  • 17. xiii Contents Using XNA Libraries 227 Playing Sounds with XNA 228 Adjusting Playback 229 Recording Sounds 230 Contacts and Appointments 233 Contacts 233 Appointments 238 Alarms and Reminders 240 Creating an Alarm 242 Creating a Reminder 244 Accessing Existing Notifications 245 Using Tasks 246 Launchers 248 Choosers 257 Media and Picture Hubs 266 Accessing Music 266 Playing Music 268 Accessing Pictures 270 Storing Pictures 272 Integrating into the Pictures Hub 274 Integrating into the Music+Videos Hub 276 Working with the Camera 280 Using the PhotoCamera Class 280 Raw Hardware Access 284 The Clipboard API 287 Live Tiles 288 Main Live Tile 289 Secondary Tiles 290 Dual-Sided Live Tiles 292 Location APIs 293 Location Permission 293 Accessing Location Information 294 Emulating Location Information 300 Where Are We? 303
  • 18. xiv Contents 8 Databases and Storage 305 Storing Data 305 Isolated Storage 306 Serialization 308 Local Databases 314 Getting Started 314 Optimizing the Context Class 320 Associations 324 Using an Existing Database 330 Schema Updates 332 Database Security 334 Where Are We? 335 9 Multitasking 337 Multitasking 337 Background Agents 338 Periodic Agent 340 Resource-Intensive Agent 348 Audio Agent 350 Background Transfer Service 360 Requirements and Limitations 360 Requesting Transfers 362 Monitoring Requests 363 Where Are We? 368 10 Services 369 The Network Stack 370 The WebClient Class 370 Accessing Network Information 373 Consuming JSON 376 Using JSON Serialization 377 Parsing JSON 379 Web Services 383 Consuming OData 387 How OData Works 388
  • 19. xv Contents The URI 389 Using OData on the Phone 398 Generating a Service Reference for OData 398 Retrieving Data 399 Updating Data 401 Using Push Notifications 403 Push Notification Requirements 404 Preparing the Application for Push Notifications 405 Setting Up the Server for Push Notifications 407 Raw Notifications 410 Sending Toast Notifications 419 Creating Live Tiles 423 Handling Push Notification Errors 427 Where Are We? 429 11 The Marketplace 431 What Is the Marketplace? 431 How It Works 432 Charging for Apps 435 Getting Paid 438 Submitting Your App 439 Preparing Your Application 439 The Submission Process 445 After the Submission 451 Modifying Your Application 453 Dealing with Failed Submissions 454 Using Ads in Your Apps 457 Where Are We? 458 Index 459
  • 21. xvii Figures FIGURE 1.1 Windows Phone Start screen 3 FIGURE 1.2 Phone screen real estate 3 FIGURE 1.3 The application bar in action 4 FIGURE 1.4 Panorama application 5 FIGURE 1.5 Last pane of a panorama application 5 FIGURE 1.6 Using Metro chrome, or not 6 FIGURE 1.7 Seven points of input 8 FIGURE 1.8 Metro’s interactive element sizes 10 FIGURE 1.9 Default keyboard 12 FIGURE 1.10 Contextual keyboards 12 FIGURE 1.11 Application lifecycle (tombstoning) 15 FIGURE 1.12 A tile in the hub 17 FIGURE 1.13 Updating tiles 17 FIGURE 1.14 Marketplace application submission process 19 FIGURE 2.1 Microsoft Visual Studio 2010 Express for Windows Phone 28 FIGURE 2.2 New Project dialog 29 FIGURE 2.3 Picking the phone version to target 29 FIGURE 2.4 The Visual Studio user interface 30 FIGURE 2.5 Enabling the toolbar 31 FIGURE 2.6 Using the emulator 31 FIGURE 2.7 The emulator 31
  • 22. xviii Figures FIGURE 2.8 Using the Visual Studio XAML design surface 33 FIGURE 2.9 Location of the Properties window 34 FIGURE 2.10 Contents of the Properties window 34 FIGURE 2.11 The changed property 35 FIGURE 2.12 Opening Blend directly in Visual Studio 36 FIGURE 2.13 The Blend user interface 37 FIGURE 2.14 Selecting an object in Blend 38 FIGURE 2.15 Selecting an object to edit in the Properties pane 38 FIGURE 2.16 Updating a property in Blend 39 FIGURE 2.17 Drawing in a container 40 FIGURE 2.18 Rounding the corners 40 FIGURE 2.19 Editing brushes 41 FIGURE 2.20 Picking a color 41 FIGURE 2.21 Inserting a TextBlock 42 FIGURE 2.22 Centering the TextBlock 42 FIGURE 2.23 Changing the text properties 43 FIGURE 2.24 Naming an element in the Properties window 45 FIGURE 2.25 Running the application 46 FIGURE 2.26 Using the Visual Studio debugger 48 FIGURE 2.27 Connected device 49 FIGURE 2.28 Your phone connected to the Zune software 49 FIGURE 2.29 Registering your device 50 FIGURE 2.30 Successfully registered developer phone 51 FIGURE 2.31 Changing the deployment to use a development phone 51 FIGURE 2.32 Running on a device 52 FIGURE 2.33 Dragging the ellipse 55 FIGURE 2.34 The SearchTask in action 57 FIGURE 2.35 Choosing a contact to retrieve an email address via the EmailAddressChooserTask 59 FIGURE 2.36 Showing the selected email in a MessageBox 59 FIGURE 3.1 Path explained 72 FIGURE 3.2 Image stretching 77 FIGURE 3.3 Transformations in action 78 FIGURE 3.4 Entire container transformed 79
  • 23. xix Figures FIGURE 4.1 TextBox control example 90 FIGURE 4.2 Software input panel (SIP) 92 FIGURE 4.3 Special SIP keys 92 FIGURE 4.4 Long-hold keys 93 FIGURE 4.5 Chat input scope 94 FIGURE 4.6 Simple button with simple content 97 FIGURE 4.7 Button with XAML content 97 FIGURE 4.8 List box 98 FIGURE 4.9 Panorama application 99 FIGURE 4.10 Panorama explained 100 FIGURE 4.11 Landscape sections 101 FIGURE 4.12 Pivot control 103 FIGURE 4.13 Pivot control in action 104 FIGURE 4.14 Looping pivot sections 104 FIGURE 4.15 Simple data binding 105 FIGURE 4.16 Changes in the source 107 FIGURE 4.17 Output window 113 FIGURE 4.18 Binding error shown in the Output window 114 FIGURE 4.19 Conversion error shown in the Output window 114 FIGURE 4.20 TemplatePart attribute 116 FIGURE 4.21 TemplateVisualState attribute 118 FIGURE 4.22 AutoCompleteBox example 120 FIGURE 4.23 ContextMenu example 121 FIGURE 4.24 Date picking user interface 123 FIGURE 4.25 Setting icons as “Content” 124 FIGURE 4.26 Time picking user interface 125 FIGURE 4.27 ListPicker example (closed) 125 FIGURE 4.28 ListPicker example (opened) 126 FIGURE 4.29 ListPicker example (full screen) 126 FIGURE 4.30 LongListSelector with groups 128 FIGURE 4.31 LongListSelector’s pop-up groups 128 FIGURE 4.32 ToggleSwitch example 132 FIGURE 4.33 ToggleSwitch components 132 FIGURE 4.34 ExpanderView in action 133 FIGURE 4.35 PhoneTextBox with the Hint and ActionIcon shown 134
  • 24. xx Figures FIGURE 4.36 PhoneTextBox’s length indication support 135 FIGURE 4.37 PhoneTextBox’s AcceptReturn functionality 136 FIGURE 4.38 Buttons in a StackPanel 137 FIGURE 4.39 Buttons in a WrapPanel 137 FIGURE 4.40 Buttons in a vertical WrapPanel 138 FIGURE 5.1 Foursquare.com 140 FIGURE 5.2 Phone-sized app 141 FIGURE 5.3 Panorama application 142 FIGURE 5.4 A sample Foursquare on Windows Phone 142 FIGURE 5.5 Sample application navigation 145 FIGURE 5.6 Single-page Windows Phone application 145 FIGURE 5.7 Sample panorama application 146 FIGURE 5.8 Panorama in the emulator 146 FIGURE 5.9 Pivot example 148 FIGURE 5.10 Pivot pages 149 FIGURE 5.11 Blend New Project dialog 150 FIGURE 5.12 Blend user interface 152 FIGURE 5.13 Blend toolbar 153 FIGURE 5.14 Projects panel 154 FIGURE 5.15 Assets panel 155 FIGURE 5.16 Objects and Timeline panel 155 FIGURE 5.17 Artboard 157 FIGURE 5.18 Item Tools panel 158 FIGURE 5.19 Searching in the Properties panel 159 FIGURE 5.20 Dragging a new control 160 FIGURE 5.21 Margin and alignment layout 160 FIGURE 5.22 Column and row gutters 161 FIGURE 5.23 Splitting the grid into rows 162 FIGURE 5.24 Modifying row/column properties 163 FIGURE 5.25 Sizing across rows 163 FIGURE 5.26 Sizing across rows with RowSpan 164 FIGURE 5.27 Brushes in the Properties panel 164 FIGURE 5.28 Converting a color to a resource 167 FIGURE 5.29 Creating a color resource 168
  • 25. xxi Figures FIGURE 5.30 Applying a color resource 168 FIGURE 5.31 Creating a brush resource 169 FIGURE 5.32 Applying a brush resource 169 FIGURE 5.33 Storyboard basics 169 FIGURE 5.34 Creating a storyboard 170 FIGURE 5.35 Objects and Timeline panel with animation 170 FIGURE 5.36 Picking the animation point 171 FIGURE 5.37 Animation mode on the artboard 171 FIGURE 5.38 The ellipse animated 172 FIGURE 5.39 Animation values in the Objects and Timeline panel 172 FIGURE 5.40 RenderTransform in an animation 173 FIGURE 5.41 Closing a storyboard 173 FIGURE 5.42 Behaviors in the Assets panel 174 FIGURE 5.43 Applying a behavior 175 FIGURE 5.44 Changing behavior properties 175 FIGURE 5.45 Multiple behaviors 176 FIGURE 5.46 ApplicationBar explained 177 FIGURE 5.47 Adding an ApplicationBar 178 FIGURE 5.48 Adding items to the ApplicationBar 178 FIGURE 5.49 Selecting a built-in icon for an ApplicationBar icon 179 FIGURE 5.50 New panorama application 180 FIGURE 5.51 PanoramaItems in the Objects and Timeline panel 180 FIGURE 5.52 Panorama control user interface 181 FIGURE 5.53 PanoramaItem selection 181 FIGURE 5.54 Adding a PanoramaItem 182 FIGURE 5.55 Creating a pivot application 183 FIGURE 5.56 A pivot application 183 FIGURE 5.57 Pivot control user interface 184 FIGURE 5.58 Editing a PivotItem 184 FIGURE 5.59 Changing device properties 185 FIGURE 6.1 Important files in a new project 188 FIGURE 6.2 Page navigation explained 191 FIGURE 6.3 URI mapping to the files in the project 192 FIGURE 6.4 How tombstoning works 196
  • 26. xxii Figures FIGURE 6.5 Portrait orientation 201 FIGURE 6.6 Landscape left orientation 201 FIGURE 6.7 Landscape right orientation 202 FIGURE 6.8 Application client area 212 FIGURE 6.9 Untilted 216 FIGURE 6.10 Tilted 216 FIGURE 7.1 Accelerometer axes 221 FIGURE 7.2 Showing the Accelerometer window in the emulator 224 FIGURE 7.3 The Accelerometer window 225 FIGURE 7.4 An alarm 240 FIGURE 7.5 A reminder 241 FIGURE 7.6 Stacked notifications 242 FIGURE 7.7 Media player controls 253 FIGURE 7.8 PhoneCallTask confirmation 255 FIGURE 7.9 Allowing photo cropping 262 FIGURE 7.10 Music library objects 267 FIGURE 7.11 Displaying the albums and pictures 272 FIGURE 7.12 The apps in the Pictures hub 274 FIGURE 7.13 Tile layers 288 FIGURE 7.14 Opening the emulator’s Additional Tools sidebar 300 FIGURE 7.15 Selecting the Location tab 301 FIGURE 7.16 Location tab of the Additional Tools dialog 301 FIGURE 7.17 Using pins to create waypoints 302 FIGURE 7.18 Saving recorded data 302 FIGURE 8.1 The SQL query 319 FIGURE 8.2 SQL Server Compact Edition database as Content 330 FIGURE 9.1 Relationship between application and scheduled task 339 FIGURE 9.2 Adding a new Scheduled Task Agent project 341 FIGURE 9.3 Picking the Windows Phone Scheduled Task Agent 341 FIGURE 9.4 Adding a reference to the Scheduled Task Agent project 344 FIGURE 9.5 The PeriodicTask’s description in the management user interface 346
  • 27. xxiii Figures FIGURE 9.6 The Universal Volume Control (UVC) in action 351 FIGURE 9.7 Adding an audio agent to your project 352 FIGURE 9.8 Making a reference to the audio agent project 353 FIGURE 10.1 Adding a service reference 383 FIGURE 10.2 The Add Service Reference dialog 384 FIGURE 10.3 Service files displayed 385 FIGURE 10.4 Adding a service reference to an OData feed 399 FIGURE 10.5 Adding a using statement to the data service 400 FIGURE 10.6 Push notification message flow 404 FIGURE 10.7 Debugging push notifications 420 FIGURE 10.8 A toast message 420 FIGURE 10.9 Tile layers 424 FIGURE 11.1 The Marketplace 432 FIGURE 11.2 The Marketplace in Zune 432 FIGURE 11.3 Submission process 433 FIGURE 11.4 The App Hub 434 FIGURE 11.5 Capability detection results 442 FIGURE 11.6 Works in the dark theme 444 FIGURE 11.7 Does not work in the light theme 444 FIGURE 11.8 Accessing your “dashboard” 445 FIGURE 11.9 Starting the submission process 446 FIGURE 11.10 Step 1 of the submission process 446 FIGURE 11.11 Filling in the descriptive fields 448 FIGURE 11.12 Pricing your app 449 FIGURE 11.13 Publish and testing options 450 FIGURE 11.14 Submission confirmation 450 FIGURE 11.15 Application lifecycle page 451 FIGURE 11.16 My Apps page 452 FIGURE 11.17 Deep link 453 FIGURE 11.18 Application actions 454 FIGURE 11.19 A failure report 455
  • 29. xxv Tables TABLE 1.1 Integrated Experiences 7 TABLE 1.2 Hardware Specifications 8 TABLE 1.3 Hardware Inputs 9 TABLE 1.4 Sample Keyboard Layouts 13 TABLE 1.5 Sensors 13 TABLE 1.6 Microsoft Phone Services 16 TABLE 2.1 Windows Phone Developer Tools Requirements 26 TABLE 3.1 Visual Containers 67 TABLE 3.2 Grid Row and Column Sizing 69 TABLE 3.3 Brush Types 73 TABLE 3.4 Transformation Types 79 TABLE 4.1 Common InputScope Values 94 TABLE 4.2 RichTextBox Markup Tags 96 TABLE 4.3 Data Binding Modes 107 TABLE 5.1 New Project Types in Blend 151 TABLE 5.2 Row/Column Sizing Icons 162 TABLE 5.3 Brush Editors 165 TABLE 5.4 Blend Behaviors 174
  • 30. xxvi Tables TABLE 6.1 Manipulation Events 207 TABLE 6.2 UIElement Touch Events 211 TABLE 7.1 FilterKind Enumeration 234 TABLE 7.2 Launchers 246 TABLE 7.3 Choosers 247 TABLE 7.4 MediaPlaybackControls Enumeration 253 TABLE 9.1 Scheduled Task Limitations 340 TABLE 10.1 OData HTTP Verb Mappings 388 TABLE 10.2 OData Query Options 391 TABLE 10.3 $filter Operators 393 TABLE 10.4 $filter Functions 394 TABLE 10.5 Push Notification Response Headers 414 TABLE 10.6 Response Codes and Header Status Codes 415 TABLE 10.7 ChannelErrorType Enumeration 429 TABLE 10.8 ChannelPowerLevel Enumeration 429 TABLE 11.1 International Pricing Example 436 TABLE 11.2 Application Images 443 TABLE 11.3 Advertising Vendors for the Phone 457
  • 31. xxvii Foreword When Shawn asked me to write a foreword for his Windows Phone devel- opment book, I had a couple of reactions. First, that they must really be scraping the bottom of the barrel if they have asked me to write anything. There are so many people who actually help bring the product to market who never really get the credit they deserve. While I am honored that I was asked to write this, based in part on my public role on the team, the engineering team that designed and built this amazing product are the real heroes. The product itself is amazing, but the right application platform, which enables the amazing Metro apps and games to be built, is a devel- oper’s playground. I do this to honor them. My second reaction was to think about the huge value Shawn has in the Microsoft ecosystem. As an eight-time MVP and Silverlight Insider, Shawn’s contributions are highly valued both for their content as well as for their reach. When Shawn speaks, you know that he has the developer in mind: He is a developer’s developer. Without individuals like Shawn, it would be tough (if possible at all) for Microsoft to have built our developer ecosystem over the last three decades. I do this to honor him. My last reaction was one of panic. I have never written a foreword before, so I was at a bit of a loss as to what I should say. I figure if you are buying this book, you did so of your own volition, and not on the strength of what I have to say here. However, if you are reading the foreword with
  • 32. xxviii Foreword an eye toward confirming your belief that Windows Phone is where it’s at, well, for that I can be accommodating. I do this to honor you. With the initial release of Windows Phone, and the subsequent pair- ing with Nokia, Microsoft is investing in building the third ecosystem for mobile developers. The canvas with which mobile developers can work on Windows Phone is unlike any other platform, whereby developers can create simply gorgeous apps with more focus on the user experience than tinkering with the innards of a convoluted framework. Metro apps come alive on the screen, and you will be able to build deeply engaging applica- tions using Live Tiles. Windows Phone 7.5 is an updated release, codenamed “Mango,” and carries with it the tagline “Put people first.” We think the same way about the developer platform. We aim to put developers first. The book you are holding might be your first step on your journey to building Windows Phone apps. It may be a refresher course. Either way, with Shawn’s guid- ance, we know that you will come away from this experience feeling great about your prospects of building amazing mobile experiences for Windows Phone, and a firm belief that Microsoft puts the developers first when we think about Windows Phone. Every developer matters. Every. Single. One. —Brandon Watson Microsoft Corporation
  • 33. xxix Preface I have never owned a PalmPilot. But I have owned palmtops and smart- phones. I dived into writing software for a plethora of different devices but never got very far. My problem was that the story of getting software onto the phones was chaotic and I didn’t see how the marketing of software for phones would lead to a successful product. In the intervening years, I got distracted by Silverlight and Web development. I didn’t pay attention as the smartphone revolution happened. I was happily neck-deep in data binding, business application development, and teaching XAML. The smartphone revolution clearly started with the iPhone. What I find interesting is that the iPhone is really about the App Store, not the phone. It’s a great device, but the App Store is what changed everything, provid- ing a simple way to publish, market, and monetize applications for these handheld powerhouses that everyone wanted. Of course, Apple didn’t mean to do it. When the original iPhone shipped, Apple clearly said that Safari (its Web browser) was the development environment. With the pres- sure of its OS X developer community, Apple relented and somewhat acci- dentally created the app revolution. When it was clear that I had missed something, I dived headlong into looking at development for phones again. I had an Android phone at the time, so that is where I started. Getting up to speed with Eclipse and Java wasn’t too hard, but developing for the phone was still a bit of a chore. The development tools just didn’t seem to be as easy as the development I was
  • 34. xxx Preface used to with Visual Studio and Blend. In this same time frame, I grabbed a Mac and tried my hand at Objective-C and Xcode to write something simple for the iPhone. That experience left me bloodied and bandaged. I wanted to write apps, but since it was a side effort, the friction of the tool sets for Android and iPhone left me wanting, and I put them aside. Soon after my experience with iPhone and Android, Microsoft took the covers off its new phone platform: Windows Phone 7. For me, the real excitement was the development experience. At that point I’d been teach- ing and writing about Silverlight since it was called WPF/E, so the ability to marry my interest in mobile development to my Silverlight knowledge seemed like a perfect match. I’ve enjoyed taking the desktop/Web Silverlight experience I have and applying the same concepts to the phone. By being able to use Visual Stu- dio and Blend to craft beautiful user interface designs and quickly go from prototype to finished application, I have found that the workflow of using these tools and XAML makes the path of building my own applications much easier than on other platforms. In the middle of this learning process Microsoft continued to mature the platform by announcing and releasing Windows Phone 7.5 (code-named Mango). I was left questioning whether to finish my Windows Phone 7 book or rush forward and mold all the new features of Windows Phone 7.5 into a book for this next version of the phone. Obviously you know the answer to that question. It has been a long road to get the right story for this book, and to help both beginners and existing Silverlight developers to learn from the book. My goal was always to allow readers to get started writing apps quickly, while also including the information that leads to great apps. Because of the relative size of these minicomputers we keep in our pockets, knowing when to pull back is often the key to a great application. As you will see throughout this book, my goal has been to help you build great apps, not rich applications. This means I will try to hold your hand as you read the book, but I will also challenge your assumptions about how you approach the process of building applications for the phone.
  • 35. xxxi Acknowledgments Writing a book is a team sport. Anyone who thinks for a moment that writ- ing a book requires that you sit in a dark room and craft words that magi- cally get bound into Amazon currency hasn’t been through the sausage factory that is book writing. The fact is that I may have the skills to get words down on virtual paper, but I am not good at much of the rest of the process. It takes a strong editor who knows how to dole out praise and pressure in equal amounts. It takes technical reviewers who aren’t afraid to ruffle your feathers. It takes production people to take the mess of Visio ramblings you call figures and create something the reader will understand. Finally, it takes an army of people to listen to your questions about the ambiguity of writing a book based on a beta version of a product . . . and who will not stop responding to your constant pestering. So I’d like to thank my army of people by acknowledging their real contributions (in no particular order). First and foremost, I want to thank my editor at Addison-Wesley, Joan Murray. I am not an easy author to work with, and she’s been a trouper in getting me to stick to deadlines and coercing me to make the right deci- sions, not just the easy ones. The rest of the people at Addison-Wesley that I’ve had the pleasure to work with are all great, too. Of special note, Christopher Cleveland did a great job picking up the role of developmen- tal editor in the middle of the book, and has been great through the whole process.
  • 36. xxxii Acknowledgments To the litany of people on the Silverlight Insiders Mailing List and the Windows Phone 7 Advisors Mailing List, I would like to thank you for your patience as I pestered the lists with endless questions and hyperbolic rants. You all helped shape this book, even if you didn’t realize it. During this process, my blog’s readers and my followers on Facebook and Twitter remained a consistent sounding board. My polls and open questions helped me shape what is and isn’t in this book. For that I am indebted to you. I also want to thank my terrific technical reviewers, Jeremy Likeness, Ambrose Little, and Bruce Little. Not only did they help me find the tons of places I just plain got it wrong, but they also helped me when the story got off track and I missed that key piece of the puzzle. Of particular note, I want to thank Ambrose for his tenacious adherence to the designer’s voice. He helped me make sure I wasn’t coddling the developers into bad user experience design. To anyone else I forgot to mention, I apologize. —Shawn Wildermuth November 2011 http://wildermuth.com @shawnwildermuth
  • 37. xxxiii About the Author During his twenty-five years in software development, Shawn Wilder- muth has experienced a litany of shifts in software development. These shifts have shaped how he understands technology. Shawn is a nine-time Microsoft MVP, a member of the INETA Speaker’s Bureau, and an author of several books on .NET. He is also involved with Microsoft as a Silver- light Insider and a Data Insider. He has spoken at a variety of interna- tional conferences, including TechEd, MIX, VSLive, OreDev, SDC, WinDev, DevTeach, DevConnections, and DevReach. He has written dozens of arti- cles for a variety of magazines and websites including MSDN, DevSource, InformIT, CoDe Magazine, ServerSide.NET, and MSDN Online. He is cur- rently teaching workshops around the United States through his training company, AgiliTrain (http://agilitrain.com).
  • 39. 1 1 Introducing Windows Phone T o some, the cell phone is an annoying necessity; to others, it’s a critical need. Being able to use a phone to make calls everywhere has really changed the way people communicate. In the past few years these phones have taken another leap forward. With the introduc- tion of iPhone and Android devices, the consumer market for an always- connected device that can interact with the Internet, run applications, and make phone calls has changed people’s relationship with their phone. It has also raised the bar for consumer-level devices. Consumers now expect their phones to also function as GPSs, gaming devices, and Internet tablets. For some consumers, their phones are now their primary connections to the Internet, replacing the desktop/laptop computer for the first time. As developers, our challenge is to find the best way to create the experiences the user needs. Windows Phone provides the platform, and Silverlight is the engine to power those experiences. A Different Kind of Phone When Microsoft originally unveiled Windows Phone 7 many skeptics expected the phone would simply try to play catch-up with Apple’s and Google’s offerings. Microsoft had other plans, though. The new operating system for the phone was a departure from existing offerings from the other mobile operating system vendors (primarily Apple, Research in Motion,
  • 40. 2 Chapter 1: Introducing Windows Phone and Google). Instead of just mimicking the icon pattern screens that iPhone and Android seemed to love, Microsoft thought in a different way. Applica- tion and operating system design is defined in a new design language code- named Metro.1 This design language defines a set of guidelines and styles for creating Windows Phone applications. The design of the Start screen laid out by Metro is similar to other smartphone designs in that it is a list of icons. Instead of separating the icons into pages, Windows Phone lets users scroll through the icons. Windows Phone is also differentiated from other smartphones in that each icon can include information about the applica- tion. These icons are called Live Tiles, as shown in Figure 1.1. What Is a Design Language? Developers think about a language as a set of textual expressions that describe some machine operation(s). For designers, it is a set of rules for defining the look and feel of a set of applications (or an entire operating system in this case). Wikipedia.org defines it more generally as “. . . an overarching scheme or style that guides the design of a complement of products or architectural settings.” The Start screen should be a place where users can quickly review the status of the phone. The Live Tiles will give user information such as the number of missed phone calls and the number of email or SMS messages waiting, or even third-party information such as the current weather. When you develop your own applications you can either create a simple icon for the Start screen or build a Live Tile for your users. For applications, the Windows Phone screen is divided into three areas in which the user can interact with the phone: the system tray, the logical client, and the application bar (see Figure 1.2). The system tray area is managed by the phone’s operating system. This is where the time, signal strength, and alerts will appear to the user. Most applications will leave this area of the screen visible to the user. Some 1. UIDesignandInteractionGuideforWindowsPhone:http://shawnw.me/wpmetroguide
  • 41. 3 A Different Kind of Phone FIGURE 1.1 Windows Phone Start screen FIGURE 1.2 Phone screen real estate
  • 42. 4 Chapter 1: Introducing Windows Phone applications (e.g., games) may hide this area, but you should only do so when critical to the success of your application. The logical client area is where your application will exist. This area shows your user interface and any data and points of interaction. The application bar shows options for your application. While using the application bar is not a requirement, it is a very common practice as it gives users access to your application’s options and menus. For example, Figure 1.3 shows a simple note-taking application that uses the applica- tion bar to allow users to create new notes or show the menu (note that the ellipsis can be clicked to open the list of menu items). One big distinction that users will see in many of the applications built into Windows Phone is the use of hubs. The central idea of a hub is to pro- vide a starting point to get the user to use natural curiosity to learn what is available in the application. Usually these hubs take the form of applica- tions that are larger than the phone screen. Instead of the typical page-based FIGURE 1.3 The application bar in action
  • 43. 5 A Different Kind of Phone applications that are fairly commonplace on smartphones, the Metro style guide introduces something called a panorama application. For panorama applications the phone is used as a window that looks into a larger applica- tion surface. You’ll notice in Figure 1.4 that the content of the screen takes up most of the horizontal real estate, but the next section of the panorama application shows up on the right side of the screen to help the user under- stand that there is more content. As the user navigates through the panorama application, the virtual space is moved within the window. For example, in Figure 1.5 you can see how, after sliding the application to the left, the rightmost part of the pano- rama becomes visible. FIGURE 1.4 Panorama application FIGURE 1.5 Last pane of a panorama application
  • 44. 6 Chapter 1: Introducing Windows Phone The use of the panorama application results in a simple but powerful user interface design that users should find very intuitive. By following the guidelines specified by Metro, you can create applica- tions that should be consistent with the rest of the phone, while giving you the freedom to create applications of any kind. In this way, Metro helps by defining basic ideas of how a Windows Phone application should look so that the user can see complete consistency. At the same time, Metro says you can simply take over the entire user interface and not use the basic ideas of the Metro chrome, leaving you the flexibility to create either cus- tom experiences or applications that look like they belong on the phone. Figure 1.6 shows example apps with and without the chrome applied. Integrated Experiences One of the main purposes of the phone is to be an integrated platform on which applications can interact with each other and with the core phone experiences. This means you can write applications that integrate with the phone in unprecedented ways. Table 1.1 outlines some of the core experi- ences users will be able to interact with and use on the phone. FIGURE 1.6 Using Metro chrome, or not
  • 45. 7 Phone Specifications As developers, your code might or might not look like the code in tra- ditional applications. Because you can write straightforward applications that can be launched in a traditional sense, the integrated experiences let your applications also interact with and even be embedded into these experiences. This means you can write applications that extend and power these experiences. Phone Specifications For Windows Phone, the stakes were high in terms of Microsoft’s ability to not only create the software but also encourage its partners to build the phone. Learning a lesson from its past Windows Mobile platform, Micro- soft decided to be very specific about the hardware to ensure a great user experience while giving phone designers some flexibility with feature sets so that they could compete with one another. Table 1.2 shows the hardware requirements. In addition, Windows Phone has physical requirements. The most obvi- ous of these is that each phone must have seven standard inputs, as shown in Figure 1.7. Table 1.3 lists and describes these seven hardware inputs. TABLE 1.1 Integrated Experiences Experience Description People The people on your phone, including contacts and past phone calls/SMS messages Office Integration with email, Word, Excel, and PowerPoint files Music+Videos The media on your device Marketplace Access to try, buy, and install applications on the phone Pictures View, share, and take pictures on your device Games Playing games on the device; this includes Xbox Live integration
  • 46. 8 Chapter 1: Introducing Windows Phone TABLE 1.2 Hardware Specifications Category Requirement Screen resolution WVGA (480 x 800) Capacitive touch At least four points of touch support Memory 256MB RAM, 8GB Flash Sensors A-GPS, Accelerometer, Compass, Light and Proximity, Gyro CPU ARM7 Scorpion/Cortex or better (typically 1GHz+) GPU DirectX 9 acceleration Camera 5 megapixels minimum, flash required Bluetooth Bluetooth 2.1 + EDR; Bluetooth profiles provided are Hand-Free Profile (HFP), Headset Profile (HSP), Advanced Audio Distribu- tion Profile (A2DP), and Phone Book Access Profile (PBAP) Multimedia Codec acceleration required; support for DivX 4, 5, and 6 as well as H.264 High Profile required (High Profile is used by Blu-ray) Wi-Fi 802.11g radio required Radio FM radio receiver required FIGURE 1.7 Seven points of input
  • 47. 9 Input Patterns Now that we have seen what the phone consists of, let’s see how users will interact with the phone. Input Patterns You are the developer. You want users to want to use your applications. That means you must deal with the different ways the phone can accept user input. Developing for the Web or desktop means you are primarily dealing with designing for the keyboard and mouse. But when developing for the phone, you have to change the way you look at input and consider that the user is going to interact with your application in different ways. Interaction patterns for the phone include touch, keyboards (hardware and software), hardware buttons, and sensors. TABLE 1.3 Hardware Inputs Input Expected Behavior 1 Power button When powered off, a long press will power on the device. If powered on and screen is active, will turn off screen and lock device. If screen is off, will enable screen and present unlock UI. 2 Volume control A rocker switch will adjust volume for current activity’s sound profile (e.g., phone call volume while on a call). Pressing volume during a phone call will disable the ringer. Adjusting volume when no activity is presently happening will allow user to switch between sound profiles. 3 Touch screen The capacitive touch screen will support at least four points of touch. 4 Camera button A long press on this dedicated button will launch the camera application. 5 Back button This button issues a “back” operation. This may take the user back in an individual application or from one applica- tion to the previous application as presented by the page API. 6 Start button This takes the user to the Start screen of the device. 7 Search button This launches the search experience to allow searching across the device.
  • 48. 10 Chapter 1: Introducing Windows Phone Designing for Touch The Metro design language is specifically constructed to make sure the interface is treating touch as a first-class citizen and that the interface requires no training (i.e., is intuitive). By building a design language that defines the elements of a touch-based interface, Microsoft has made it eas- ier to build such interfaces. The design language includes guidelines for what touch gestures are supported, as well as how to space and size ele- ments for finger-size interactions. Figure 1.8 shows an example from Metro to define the minimum sizes for touch points and their spacing. Metro also defines the types of interactions (e.g., touch gestures) the device supports. Most of these interactions are well-worn gestures that have been the vocabulary of other touch devices such as the iPhone, Zune HD, and Android. These interactions include • Single touch: − Tap − Double-Tap − Pan − Flick − Touch and Hold • Multitouch: − Pinch/Stretch/Rotate 2 mm/8 px Minimum Space between Touch Targets 7 mm/26 px Minimum Object Size 9 mm/34 px Touch Target FIGURE 1.8 Metro’s interactive element sizes
  • 49. Discovering Diverse Content Through Random Scribd Documents
  • 50. scene in the house of Castlewood with the Prince, reveals her true nature and quits the room in a rage. The supposed author writes: “Her keen words gave no wound to Mr. Esmond; his heart was too hard. As he looked at her, he wondered that he could ever have loved her.... The Prince blushed and bowed low, as she gazed at him and quitted the chamber. I have never seen her from that day.” Thackeray made this slip on purpose. He wanted us to feel the reality of the man who is trying to tell his own story in the third person. This, after all, is the real value of the book. It is not only a wonderful picture of the Age of Queen Anne, its ways and customs, its manner of speech and life, its principal personages—the red- faced queen, and peremptory Marlborough, and smooth Atterbury, and rakish Mohun, and urbane Addison, and soldier-scholar Richard Steele—appearing in the background of the political plot. It is also, and far more significantly, a story of the honour of a gentleman— namely, Henry Esmond—carried through a life of difficulty, and crowned with the love of a true woman, after a false one had failed him. Some readers profess themselves disappointed with the dénouement of the love-story. They find it unnatural and disconcerting that the hero should win the mother and not the daughter as the guerdon of his devotion. Not I. Read the story more closely. When it opens, in the house of Castlewood, Esmond is a grave, lonely boy of twelve; Lady Castlewood, fair and golden-haired, is in the first bloom of gracious beauty, twenty years old; Beatrix is a dark little minx of four years. Naturally, Henry falls in love with the mother rather than with the daughter, grows up as her champion and knight, defends her against the rakishness of Lord Mohun, resolves for her sake to give up his claim to the title and the estate. Then comes the episode of his infatuation by the wonderful physical beauty of Beatrix, the vixen. That madness ends with the self-
  • 51. betrayal of her letter of assignation with the Prince, and her subsequent conduct. Esmond returns to his first love, his young love, his true love, Lady Castlewood. Of its fruition let us read his own estimate: “That happiness which hath subsequently crowned it, cannot be written in words; it is of its nature sacred and secret, and not to be spoken of, though the heart be ever so full of thankfulness, save to Heaven and the One Ear alone—to one fond being, the truest and tenderest and purest wife ever man was blessed with.” III I have left myself scant space to speak of Thackeray’s third phase in writing—his work as a moralist. But perhaps this is well, for, as he himself said, (and as I have always tried to practise), the preacher must be brief if he wishes to be heard. Five words that go home are worth more than a thousand that wander about the subject. Thackeray’s direct moralizings are to be found chiefly in his lectures on “The Four Georges,” “The English Humourists,” and in the “Roundabout Papers.” He was like Lowell: as a scholastic critic he was far from infallible, but as a vital interpreter he seldom missed the mark. After all, the essential thing in life for us as real men is to have a knowledge of facts to correct our follies, an ideal to guide our efforts, and a gospel to sustain our hopes. That was Thackeray’s message as moralist. It is expressed in the last paragraph of his essay “Nil Nisi Bonum,” written just after the death of Macaulay and Washington Irving: “If any young man of letters reads this little sermon—and to him, indeed, it is addressed—I would say to him, ‘Bear Scott’s words in your mind, and be good, my dear.’ Here are two literary men gone to their account, and, laus Deo, as far as we know, it is fair, and open, and clean. Here is no need of apologies for shortcomings, or
  • 52. explanations of vices which would have been virtues but for unavoidable, etc. Here are two examples of men most differently gifted—each pursuing his calling; each speaking his truth as God bade him; each honest in his life; just and irreproachable in his dealings; dear to his friends; honoured by his country; beloved at his fireside. It has been the fortunate lot of both to give incalculable happiness and delight to the world, which thanks them in return with an immense kindliness, respect, affection. It may not be our chance, brother scribe, to be endowed with such merit, or rewarded with such fame. But the rewards of these men are rewards paid to our service. We may not win the bâton or epaulettes; but God give us strength to guard the honour of the flag!” With this supplication for myself and for others, I leave this essay on Thackeray, the greatest of English novelists, to the consideration of real men.
  • 53. GEORGE ELIOT AND REAL WOMEN George Eliot was a woman who wrote full-grown novels for men. Other women have done and are doing notable work in prose fiction—Jane Austen, George Sand, Charlotte Brontë, Mrs. Stowe, Margaret Deland, Edith Wharton, Katharine Fullerton Gerould, Mrs. Humphry Ward—the list might easily be extended, but it would delay us from the purpose of this chapter. Let me rather make a general salute to all the sisterhood who have risen above the indignity of being called “authoresses,” and, without pursuing perilous comparisons, go directly to the subject in hand. What was it that enabled George Eliot to enter the field of the English novel at a time when Dickens and Thackeray were at the height of their fame, and win a place in the same class with them? It was certainly not the hide-and-seek of the sex of the new writer under a pseudonym. You remember, opinions were divided on this question. Carlyle and Thackeray thought that the author of Scenes of Clerical Life was a man. Dickens was sure that it was a woman. But a mystification of this kind has no interest apart from the primary value of the works of the unidentified writer in question. Nor does it last long as an advertisement, unless the following books excel the first; and, in that case, the secret is sure to be soon discovered. George Eliot’s success and distinction as a novelist were due to three things: first, the preliminary and rather obvious advantage of having genius; second, a method of thinking and writing which is commonly (though perhaps arrogantly) called masculine; third, a quickness of insight into certain things, a warmth of sympathy for
  • 54. suffering, and an instinct of sacrifice which we still regard (we hope rightly) as feminine. A man for logic, a woman for feeling, a genius for creative power—that was a great alliance. But the womanhood kept the priority without which it would not only have died out, but also have endangered, in dying, the other qualities. Dickens was right when he said of certain touches in the work of this pseudonymous writer: “If they originated with no woman, I believe that no man ever before had the art of making himself mentally so like a woman since the world began.” George Eliot’s profile resembled Savonarola’s. He was one of her heroes. But she was not his brother. She was his sister in the spirit. Her essential femininity was the reason why the drawing of her women surpassed the drawing of her men. It was more intimate, more revealing, more convincing. She knew women better. She painted them of many types and classes—from the peasant maid to the well-born lady, from the selfish white cat to the generous white swan-sister; from the narrow-minded Rosamund to the deep- hearted, broad-minded Romola; all types, I think, but one—the lewdly carnal Circe. In all her books, with perhaps a single exception, it is a woman who stands out most clearly from the carefully studied and often complex background as the figure of interest. And even in that one it is the slight form of Eppie, the golden-hearted girl who was sent to save old Silas Marner from melancholy madness, that shines brightest in the picture. The finest of her women—finest not in the sense of being faultless, but of having in them most of that wonderful sacrificial quality which Goethe called das ewig Weibliche—were those upon whose spiritual portraits George Eliot spent her most loving care and her most graphic skill. She shows them almost always in the revealing light of love. But she does not dwell meticulously on the symptoms or the course of the merely physical attraction. She knows that it is there; she confesses that it is potent. But it seems to her, (as indeed it really is,) far more uniform and less interesting than the meaning of love in
  • 55. the soul of a woman as daughter, sister, sweetheart, wife. Were it not for that inward significance there would be little to differentiate the physical act from the mating of the lower animals—an affair so common and casual that it merits less attention than some writers give it. But in the inner life of thought and emotion, in a woman’s intellectual and moral nature,—there love has its mystery and its power, there it brings deepest joy or sharpest sorrow, there it strengthens or maims. It is because George Eliot knows this and reveals it with extraordinary clearness that her books have an especial value. Other qualities they have, of course, and very high qualities. But this is their proper and peculiar excellence, and the source, if I mistake not, of their strongest appeal to sanely thinking men. The Man Who Understood Woman is the title of a recent clever trivial story. But of course such a man is a myth, an impostor, or a self-deluder. He makes a preposterous claim. Thackeray and Dickens, for example, made no such pretension. Some of their women are admirably drawn; they are very lovable, or very despicable, as the case may be; but they are not completely convincing. Thackeray comes nearer than Dickens, and George Meredith, I think, much nearer than either of the others. But in George Eliot we feel that we are listening to one who does understand. Her women, in their different types, reveal something of that thinking, willing, feeling other-half of humanity with whom man makes the journey of life. They do not cover all the possibilities of variation in the feminine, for these are infinite, but they are real women, and so they have an interest for real men. Let us take it for granted that we know enough of the details of George Eliot’s life to enable us to understand and appreciate certain things in her novels. Such biographical knowledge is illuminating in the study of the works of any writer. The author of a book is not an algebraic quantity nor a strange monster, but a human being with certain features and a certain life-history.
  • 56. But, after all, the promotion of literary analysis is not the object of these chapters. Plain reading, and the pleasure of it, is what I have in mind. For that cause I love most of George Eliot’s novels, and am ready to maintain that they are worthy to be loved. And so, even if my “taken for granted” a few lines above should not be altogether accurate in these days of ignorant contempt of all that is “Victorian,” I may still go ahead to speak of her books as they are in themselves: strong, fine, rewarding pieces of English fiction: that is what they would remain, no matter who had written them. It must be admitted at once that they are not adapted to readers who like to be spared the trouble of thinking while they read. They do not belong to the class of massage-fiction, Turkish-bath novels. They require a certain amount of intellectual exercise; and for this they return, it seems to me, an adequate recompense in the pleasurable sense of quickened mental activity and vigour. But this admission must not be taken to imply that they are obscure, intricate, enigmatical, “tough reading,” like the later books of George Meredith and Henry James, in which a minimum of meaning is hidden in a maximum of obfuscated verbiage, and the reader is invited to a tedious game of hunt-the-slipper. On the contrary, George Eliot at her best is a very clear writer—decidedly not shallow, nor superficial, nor hasty,—like the running comment which is supposed to illuminate the scenes in a moving-picture show, —but intentionally lucid and perspicuous. Having a story to tell, she takes pains to tell it so that you can follow it, not only in its outward, but also in its inward movement. Having certain characters to depict (and almost always mixed characters of good and evil mingled and conflicting as in real life), she is careful to draw them so that you shall feel their reality and take an interest in their strifes and adventures. They are distinctly persons, capable of making their own choice between the worse and the better reason, and thereafter influenced by the consequences of that choice, which, if repeated, becomes a habit of moral victory or defeat. They are not puppets in, the hands
  • 57. of an inscrutable Fate, like most of the figures in the books of the modern Russian novelists and their imitators. What do I care for the ever-so realistically painted marionettes in the fiction of Messrs. Gawky, Popoff, Dropoff, and Slumpoff? What interest have I in the minute articulations of the dingy automatons of Mijnheer Couperus, or the dismal, despicable figures who are pulled through the pages of Mr. Samuel Butler’s The Way of All Flesh? A claim on compassion they might have if they were alive. But being, by the avowal of their creators, nothing more than imaginary bundles of sensation, helpless playthings of irresistible hereditary impulse and entangling destiny, their story and their fate leave me cold. What does it matter what becomes of them? They can neither be saved nor damned. They can only be drifted. There is no more human interest in them than there is in the predestined saints and foredoomed sinners of a certain type of Calvinistic theology. But this is not George Eliot’s view of life. It is not to her “a tale told by an idiot, full of sound and fury signifying nothing.” Within the fixed circle of its stern natural and moral laws there is a hidden field of conflict where the soul is free to discern and choose its own cause, and to fight for it or betray it. However small that field may be, while it exists life has a meaning, and personalities are real, and the results of their striving or surrendering, though rarely seen complete or final, are worth following and thinking about. Thus George Eliot’s people—at least the majority of them—have the human touch which justifies narrative and comment. We follow the fortunes of Dinah Morris and of Maggie Tulliver, of Romola, and of Dorothea Brooke—yes, and of Hetty Sorrel and Rosamund Vincy— precisely because we feel that they are real women and that the turning of their ways will reveal the secret of their hearts. It is a mistake to think (as a recent admirable essay of Professor W. L. Cross seems to imply) that the books of George Eliot are characteristically novels of argument or propaganda. Once only, or perhaps twice, she yielded to that temptation and spoiled her story. But for the rest she kept clear of the snare of Tendenz.
  • 58. Purpose-novels, like advertisements, belong in the temporary department. As certain goods and wares go out of date, and the often eloquent announcements that commended them suddenly disappear; even so the “burning questions” of the hour and age burn out, and the solutions of them presented in the form of fiction fall down with the other ashes. They have served their purpose, well or ill, and their transient importance is ended. What endures, if anything, is the human story vividly told, the human characters graphically depicted. These have a permanent value. These belong to literature. Here I would place Adam Bede and Silas Marner and The Mill on the Floss and Middlemarch, because they deal with problems which never grow old; but not Robert Elsmere, because it deals chiefly with a defunct controversy in Biblical criticism. George Eliot was thirty-eight years old when she made the amazing discovery that she was by nature, not what she had thought herself, a philosophical essayist and a translator of arid German treatises against revealed religion, but something very different—a novelist of human souls, and especially of the souls of women. It was the noteworthy success of her three long short stories, Amos Barton, Mr. Gilfil’s Love Story, and Janet’s Repentance, printed in Blackwood’s Magazine in 1857, that revealed her to herself and to the world. “Depend upon it, [she says to her imaginary reader in the first of these stories,] you would gain unspeakably if you would learn with me to see something of the poetry and the pathos, the tragedy and the comedy, lying in the experience of the human soul that looks out through dull gray eyes and speaks in a voice of quite ordinary tones.” It was the interior drama of human life that attracted her interest and moved her heart with pity and fear, laughter and love. She found it for the most part in what we should call mediocre surroundings and on rather a humble and obscure stage. But what she found was not mediocre. It was the same discovery that Wordsworth made:
  • 59. “A grandeur in the beatings of the heart.” By this I do not mean to say that a close study of the humanness of human nature, a searching contemplation of character, an acute and penetrating psychological analysis is all that there is in her novels. This is her predominant interest, beyond a doubt. She belongs to the school of Hawthorne, Henry James, Thomas Hardy— realists or romancers of the interior life. But she has other interests; and there are other things to reward us in the reading of her books. There is, first of all, an admirable skill in the setting of her stories. No other novelist has described English midland landscape, towns, and hamlets, better than she. No other writer has given the rich, history-saturated scenery of Florence as well. She is careful also not to exclude from her stage that messenger of relief and contrast whom George Meredith calls “the comic spirit.” Shakespeare’s clowns, wonderful as some of them are, seem at times like supernumeraries. They come in to make a “diversion.” But George Eliot’s rustic wits and conscious or unconscious humourists belong to the story. Mrs. Poyser and Bartle Massey, Mrs. Glegg and Mrs. Tulliver and Bob Jakin, could not be spared. And then, her stories are really stories. They have action. They move; though sometimes, it must be confessed, they move slowly. Not only do the characters develop, one way or the other, but the plot also develops. Sometimes it is very simple, as in Silas Marner; sometimes it is extremely complicated, as in Middlemarch, where three love-stories are braided together. One thing it never is— theatrical. Yet at times it moves into an intense scene, like the trial of Hetty Sorrel or the death of Tito Melema, in which the very essence of tragedy is concentrated. From the success of Scenes of Clerical Life George Eliot went on steadily with her work in fiction, never turning aside, never pausing even, except when her health compelled, or when she needed time
  • 60. to fill her mind and heart with a new subject. She did not write rapidly, nor are her books easy to read in a hurry. It was an extraordinary series: Adam Bede in 1859, The Mill on the Floss in 1860, Silas Marner in 1861, Romola in 1863, Felix Holt, the Radical in 1866, Middlemarch in 1871, Daniel Deronda in 1876; no padding, no “seconds,” each book apparently more successful, certainly more famous, than its predecessor. How could one woman produce so much closely wrought, finely finished work? Of what sturdy mental race were the serious readers who welcomed it and found delight in it? Mr. Oscar Browning of Cambridge said that Daniel Deronda was the climax, “the sun and glory of George Eliot’s art.” From that academic judgment I venture to dissent. It is a great book, no doubt, the work of a powerful intellect. But to me it was at the first reading, and is still, a tiresome book. Tediousness, which is a totally different thing from seriousness, is the unpardonable defect in a novel. It may be my own fault, but Deronda seems to me something of a prig. Now a man may be a prig without sin, but he ought not to take up too much room. Deronda takes up too much room. And Gwendolen Harleth, who dressed by preference in sea-green, seems to me to have a soul of the same colour—a psychological mermaid. She is unconvincing. I cannot love her. The vivid little Jewess, Mirah, is the only character with charm in the book. Middlemarch is noteworthy for its extraordinary richness of human observation and the unexcelled truthfulness of some of its portraits. Mr. Isaac Casaubon is the living image of the gray-minded scholar and gentleman,—as delicately drawn as one of Miss Cecelia Beaux’ portraits of aged, learned, wrinkled men. Rosamund Vincy is the typical “daughter of the horse-leech” in respectable clothes and surroundings. Dorothea Brooke is one of George Eliot’s finest sacrificial heroines: “A perfect woman, nobly plann’d.”
  • 61. The book, as a whole, seems to me to have the defect of superabundance. There is too much of it. It is like one of the late William Frith’s large canvases, “The Derby Day,” or “The Railway Station.” It is constructed with skill, and full of rich material, but it does not compose. You cannot see the people for the crowd. Yet there is hardly a corner of the story in which you will not find something worth while. Felix Holt, the Radical is marred, at least for me, by a fault of another kind. It is a novel of problem, of purpose. I do not care for problem-novels, unless the problem is alive, and even then I do not care very much for political economy in that form. It is too easy for the author to prove any proposition by attaching it to a noble character, or to disprove any theory by giving it an unworthy advocate. English radicalism of 1832 has quite passed away, or gone into the Coalition Cabinet. All that saves Felix Holt now (as it seems to me, who read novels primarily for pleasure) is the lovely figure of Esther Lyon, and her old father, a preacher who really was good. Following the path still backward, we come to something altogether different. Romola is a historical romance on the grand scale. In the central background is the heroic figure of Savonarola, saintly but not impeccable; in the middle distance, a crowd of Renaissance people immersed in the rich and bloody turmoil of that age; in the foreground, the sharp contrast of two epic personalities— Tito Melema, the incarnation of smooth, easy-going selfishness which never refuses a pleasure nor accepts a duty; and Romola, the splendid embodiment of pure love in self-surrendering womanhood. The shameful end of Tito, swept away by the flooded river Arno and finally choked to death by the father whom he had disowned and wronged, has in it the sombre tone of Fate. But the end of the book is not defeat; it is triumph. Romola, victor through selfless courage and patience, saves and protects the deserted mistress and children of her faithless husband. In the epilogue we see her like Notre Dame de Secours, throned in mercy and crowned with compassion.
  • 62. Listen to her as she talks to Tito’s son in the loggia looking over Florence to the heights beyond Fiesole. “‘What is it, Lillo?’ said Romola, pulling his hair back from his brow. Lillo was a handsome lad, but his features were turning out to be more massive and less regular than his father’s. The blood of the Tuscan peasant was in his veins. “‘Mamma Romola, what am I to be?’ he said, well contented that there was a prospect of talking till it would be too late to con Spirto gentil any longer. “‘What should you like to be, Lillo? You might be a scholar. My father was a scholar, you know, and taught me a great deal. That is the reason why I can teach you.’ “‘Yes,’ said Lillo, rather hesitatingly. ‘But he is old and blind in the picture. Did he get a great deal of glory?’ “‘Not much, Lillo. The world was not always very kind to him, and he saw meaner men than himself put into higher places, because they could flatter and say what was false. And then his dear son thought it right to leave him and become a monk; and after that, my father, being blind and lonely, felt unable to do the things that would have made his learning of greater use to men, so that he might still have lived in his works after he was in his grave.’ “‘I should not like that sort of life,’ said Lillo. ‘I should like to be something that would make me a great man, and very happy besides—something that would not hinder me from having a good deal of pleasure.’ “‘That is not easy, my Lillo. It is only a poor sort of happiness that could ever come by caring very much about our own narrow pleasures. We can only have the highest happiness, such as goes along with being a great man, by having wide thoughts, and feeling for the rest of the world as well as ourselves; and this sort of happiness often brings so much pain with it, that we can only tell it from pain by its being what we would choose before everything else, because our souls see it is good. There are so many things wrong
  • 63. and difficult in the world, that no man can be great—he can hardly keep himself from wickedness—unless he gives up thinking much about pleasure or rewards, and gets strength to endure what is hard and painful. My father had the greatness that belongs to integrity; he chose poverty and obscurity rather than falsehood. And there was Fra Girolamo—you know why I keep to-morrow sacred: he had the greatness which belongs to a life spent in struggling against powerful wrong, and in trying to raise men to the highest deeds they are capable of. And so, my Lillo, if you mean to act nobly and seek to know the best things God has put within reach of men, you must learn to fix your mind on that end, and not on what will happen to you because of it. And remember, if you were to choose something lower, and make it the rule of your life to seek your own pleasure and escape from what is disagreeable, calamity might come just the same; and it would be calamity falling on a base mind, which is the one form of sorrow that has no balm in it, and that may well make a man say, “It would have been better for me if I had never been born.” I will tell you something, Lillo.’ “Romola paused for a moment. She had taken Lillo’s cheeks between her hands, and his young eyes were meeting hers. “‘There was a man to whom I was very near, so that I could see a great deal of his life, who made almost every one fond of him, for he was young, and clever, and beautiful, and his manners to all were gentle and kind. I believe, when I first knew him, he never thought of anything cruel or base. But because he tried to slip away from everything that was unpleasant, and cared for nothing else so much as his own safety, he came at last to commit some of the basest deeds—such as make men infamous. He denied his father, and left him to misery; he betrayed every trust that was reposed in him, that he might keep himself safe and get rich and prosperous. Yet calamity overtook him.’ “Again Romola paused. Her voice was unsteady, and Lillo was looking up at her with awed wonder.
  • 64. “‘Another time, my Lillo—I will tell you another time. See, there are our old Piero di Cosimo and Nello coming up the Borgo Pinti, bringing us their flowers. Let us go and wave our hands to them, that they may know we see them.’” Hardly one of George Eliot’s stories has a conventional “happy ending.” Yet they leave us not depressed, but strengthened to endure and invigorated to endeavour. In this they differ absolutely from the pessimistic novels of the present hour, which not only leave a bad taste in the mouth, but also a sense of futility in the heart. Let me turn now to her first two novels, which still seem to me her best. Bear in mind, I am not formulating academic theories, nor pronouncing ex cathedrâ judgments, but simply recording for the consideration of other readers certain personal observations and reactions. Adam Bede is a novel of rustic tragedy in which some of the characters are drawn directly from memory. Adam is a partial portrait of George Eliot’s father, and Dinah Morris a sketch of her aunt, a Methodist woman preacher. There is plenty of comic relief in the story, admirably done. Take the tongue duel between Bartle Massey, the sharp-spoken, kind-hearted bachelor school-master, and Mrs. Poyser, the humorous, pungent, motherly wife of the old farmer. “‘What!’ said Bartle, with an air of disgust. ‘Was there a woman concerned? Then I give you up, Adam.’ “‘But it’s a woman you’n spoke well on, Bartle,’ said Mr. Poyser. ‘Come, now, you canna draw back; you said once as women wouldna ha’ been a bad invention if they’d all been like Dinah.’ “‘I meant her voice, man—I meant her voice, that was all,’ said Bartle. ‘I can bear to hear her speak without wanting to put wool in my ears. As for other things, I dare say she’s like the rest o’ the women—thinks two and two ’ull come to make five, if she cries and bothers enough about it.’ “‘Ay, ay!’ said Mrs. Poyser; ‘one ’ud think, an’ hear some folks talk, as the men war ’cute enough to count the corns in a bag o’ wheat
  • 65. wi’ only smelling at it. They can see through a barn door, they can. Perhaps that’s the reason they can see so little o’ this side on’t.’ “‘Ah!’ said Bartle, sneeringly, ‘the women are quick enough— they’re quick enough. They know the rights of a story before they hear it, and can tell a man what his thoughts are before he knows ’em himself.’ “‘Like enough,’ said Mrs. Poyser; ‘for the men are mostly so slow, their thoughts overrun ’em, an’ they can only catch ’em by the tail. I can count a stocking-top while a man’s getting’s tongue ready; an’ when he outs wi’ his speech at last, there’s little broth to be made on’t. It’s your dead chicks take the longest hatchin’. Howiver, I’m not denyin’ the women are foolish: God Almighty made ’em to match the men.’ “‘Match!’ said Bartle; ‘ay, as vinegar matches one’s teeth. If a man says a word, his wife’ll match it with a contradiction; if he’s a mind for hot meat, his wife’ll match it with cold bacon; if he laughs, she’ll match him with whimpering. She’s such a match as the horsefly is to th’ horse: she’s got the right venom to sting him with—the right venom to sting him with.’ “‘What dost say to that?’ said Mr. Poyser, throwing himself back and looking merrily at his wife. “‘Say!’ answered Mrs. Poyser, with dangerous fire kindling in her eye; ‘why, I say as some folks’ tongues are like the clocks as run on strikin’, not to tell you the time o’ the day, but because there’s summat wrong i’ their own inside.’ ...” The plot, as in Scott’s Heart of Midlothian, turns on a case of seduction and child murder, and the contrast between Effie and Jeannie Deans has its parallel in the stronger contrast between Hetty Sorrel and Dinah Morris. Hetty looked as if she were “made of roses”; but she was, in Mrs. Poyser’s phrase, “no better nor a cherry wi’ a hard stone inside it.” Dinah’s human beauty of face and voice was the true reflection of her inward life which
  • 66. “cast a beam on the outward shape, The unpolluted temple of the mind, And turned it by degrees to the soul’s essence.” The crisis of the book comes in the prison, where Dinah wrestles for the soul of Hetty—a scene as passionate and moving as any in fiction. Dinah triumphs, not by her own might, but by the sheer power and beauty of the Christian faith and love which she embodies. In George Eliot’s novels you will find some passages of stinging and well-merited satire on the semi-pagan, conventional religion of middle-class orthodoxy in England of the nineteenth century—“proud respectability in a gig of unfashionable build; worldliness without side-dishes”—read the chapter on “A Variation of Protestantism Unknown to Bossuet,” in The Mill on the Floss. But you will not find a single page or paragraph that would draw or drive the reader away from real Christianity. On the contrary, she has expressed the very secret of its appeal to the human heart through the words and conduct of some of her best characters. They do not argue; they utter and show the meaning of religion. On me the effect of her books is a deepened sense of the inevitable need of Christ and his gospel to sustain and nourish the high morality of courage and compassion, patience, and hope, which she so faithfully teaches. The truth is, George Eliot lived in the afterglow of Christian faith. Rare souls are capable of doing that. But mankind at large needs the sunrise. The Mill on the Floss is partly an autobiographic romance. Maggie Tulliver’s character resembles George Eliot in her youth. The contrast between the practical and the ideal, the conflict between love and duty in the heart of a girl, belong to those problematische Naturen, as Goethe called them, which may taste keen joys but cannot escape sharp sorrows. The centre of the story lies in Maggie’s strong devotion to her father and to her brother Tom—a person not
  • 67. altogether unlike the “elder brother” in the parable—in strife with her love for Philip, the son of the family enemy. Tom ruthlessly commands his sister to choose between breaking with him and giving up her lover. Maggie, after a bitter struggle, chooses her brother. Would a real woman do that? Yes, I have known some very real women who have done it, in one case with a tragic result. The original title of this book (and the right one) was Sister Maggie. Yet we can see why George Eliot chose the other name. The little river Floss, so tranquil in its regular tidal flow, yet capable of such fierce and sudden outbreaks, runs through the book from beginning to end. It is a mysterious type of the ineluctable power of Nature in man’s mortal drama. In the last chapter, when the flood comes, and the erring sister who loved her brother so tenderly, rescues him who loved her so cruelly from the ruined mill, the frail skiff which carries them clasped heart to heart, reconciled in that revealing moment, goes down in the senseless irresistible rush of waters. It is not a “bad ending.” The sister’s love triumphs. Such a close was inevitable for such a story. But it is not a conclusion. It cries out for immortality. On the art of George Eliot judgments have differed. Mr. Oscar Browning, a respectable authority, thinks highly of it. Mr. W. C. Brownell, a far better critic, indeed one of the very best, thinks less favourably of it, says that it is too intellectual; that the development and conduct of her characters are too logical and consistent; that the element of surprize, which is always present in life, is lacking in her people. “Our attention,” he writes, “is so concentrated on what they think that we hardly know how they feel, or whether ... they feel at all.” This criticism does not seem to me altogether just. Certainly there is no lack of surprize in Maggie Tulliver’s temporary infatuation with the handsome, light-minded Stephen Guest, or in Dorothea Brooke’s marriage to that heady young butterfly, Will Ladislaw. These things certainly were not arrived at by logical
  • 68. consistency. Nor can one lay his hand on his heart and say that there is no feeling in the chapter where the fugitive Romola comes as Madonna to the mountain village, stricken by pestilence, or in the passage where Dinah Morris strives for Hetty’s soul in prison. George Eliot herself tells us the purpose of her art—it is verity. “It is for this rare, precious quality of truthfulness that I delight in many Dutch paintings, which lofty-minded people despise.... All honour and reverence to the divine beauty of form! Let us cultivate it to the utmost in men, women, and children—in our gardens and in our homes. But let us love that other beauty, too, which lies in no secret of proportion, but in the secret of deep human sympathy.” It is Rembrandt, then, rather than Titian, who is her chosen painter. But she does not often attain his marvellous chiaroscuro. Her style is clear and almost always firm in drawing, though deficient in colour. It is full of meaning, almost over-scrupulous in defining precisely what she wishes to express. Here and there it flashes into a wise saying, a sparkling epigram. At other times, especially in her later books, it spreads out and becomes too diffuse, too slow, like Sir Walter Scott’s. But it never repels by vulgar smartness, nor perplexes by vagueness and artificial obscurity. It serves her purpose well—to convey the results of her scrutiny of the inner life and her loving observation of the outer life in its humblest forms. In these respects it is admirable and satisfying. And it is her own—she does not imitate, nor write according to a theory. Her general view of human nature is not essentially different from that expressed in a passage which I quoted from Thackeray in the previous chapter. We are none of us “irreproachable characters.” We are “mixed human beings.” Therefore she wishes to tell her stories “in such a way as to call forth tolerant judgment, pity, and sympathy.” As I began so let me end this chapter—with a word on women. For myself, I think it wise and prudent to maintain with Plutarch that
  • 69. virtue in man and woman is one and the same. Yet there is a difference between the feminine and the masculine virtues. This opinion Plutarch sets forth and illustrates in his brief histories, and George Eliot in her novels. But of the virtues of women she gives more and finer examples.
  • 70. THE POET OF IMMORTAL YOUTH One of the things that surprized and bewildered old Colonel Newcome when he gathered his boy’s friends around the mahogany tree in the dull, respectable dining-room at 12 Fitzroy Square, was to hear George Warrington declare, between huge puffs of tobacco smoke, “that young Keats was a genius to be estimated in future days with young Raphael.” At this Charles Honeyman sagely nodded his ambrosial head, while Clive Newcome assented with sparkling eyes. But to the Colonel, sitting kindly grave and silent at the head of the table, and recalling (somewhat dimly) the bewigged and powdered poetry of the age of Queen Anne, such a critical sentiment seemed radical and revolutionary, almost ungentlemanly. How astonished he would have been sixty years later if he had taken up Mr. Sidney Colvin’s Life of Keats, in the “English Men of Letters Series,” and read in the concluding chapter the deliberate and remarkable judgment that “by power, as well as by temperament and aim, he was the most Shakespearean spirit that has lived since Shakespeare”! In truth, from the beginning the poetry of Keats has been visited too much by thunder-storms of praise. It was the indiscriminate enthusiasm of his friends that drew out the equally indiscriminate ridicule of his enemies. It was the premature salutation offered to him as a supreme master of the most difficult of all arts that gave point and sting to the criticism of evident defects in his work. The Examiner hailed him, before his first volume had been printed, as one who was destined to revive the early vigour of English poetry. Blackwood’s Magazine retorted by quoting his feeblest lines and
  • 71. calling him “Johnny Keats.” The suspicion of log-rolling led to its usual result in a volley of stone-throwing. Happily, the ultimate fame and influence of a true poet are not determined by the partizan conflicts which are waged about his name. He may suffer some personal loss by having to breathe, at times, a perturbed atmosphere of mingled flattery and abuse instead of the still air of delightful studies. He may be robbed of some days of a life already far too short, by the pestilent noise and confusion arising from that scramble for notoriety which is often unduly honoured with the name of “literary activity.” And there are some men whose days of real inspiration are so few, and whose poetic gift is so slender, that this loss proves fatal to them. They are completely carried away and absorbed by the speculations and strifes of the market-place. They spend their time in the intrigues of rival poetic enterprises, and learn to regard current quotations in the trade journals as the only standard of value. Minor poets at the outset, they are tempted to risk their little all on the stock exchange of literature, and, losing their last title to the noun, retire to bankruptcy on the adjective. But Keats did not belong to this frail and foolish race. His lot was cast in a world of petty conflict and ungenerous rivalry, but he was not of that world. It hurt him a little, but it did not ruin him. His spiritual capital was too large, and he regarded it as too sacred to be imperilled by vain speculations. He had in Chaucer and Spenser, Shakespeare and Chapman, Milton and Petrarch, older and wiser friends than Leigh Hunt. For him “The blue Bared its eternal bosom, and the dew Of summer nights collected still to make The morning precious: beauty was awake!”
  • 72. He perceived, by that light which comes only to high-souled and noble-hearted poets, “The great end Of poesy, that it should be a friend To soothe the cares and lift the thoughts of man.” To that end he gave the best that he had to give, freely, generously, joyously pouring himself into the ministry of his art. He did not dream for a moment that the gift was perfect. Flattery could not blind him to the limitations and defects of his early work. He was his own best and clearest critic. But he knew that so far as it went his poetic inspiration was true. He had faithfully followed the light of a pure and elevating joy in the opulent, manifold beauty of nature and in the eloquent significance of old-world legends, and he believed that it had already led him to a place among the poets whose verse would bring delight, in far-off years, to the sons and daughters of mankind. He believed also that if he kept alive his faith in the truth of beauty and the beauty of truth it would lead him on yet further, into a nobler life and closer to those immortal bards whose “Souls still speak To mortals of their little week; Of their sorrows and delights; Of their passions and their spites; Of their glory and their shame; What doth strengthen and what maim.” He expressed this faith very clearly in the early and uneven poem called “Sleep and Poetry,” in a passage which begins
  • 73. “Oh, for ten years, that I may overwhelm Myself in poesy! so I may do the deed That my own soul has to itself decreed.” And then, ere four years had followed that brave wish, his voice fell silent under a wasting agony of pain and love, and the daisies were growing upon his Roman grave. The pathos of his frustrated hope, his early death, has sometimes blinded men a little, it seems to me, to the real significance of his work and the true quality of his influence in poetry. He has been lamented in the golden verse of Shelley’s “Adonaïs,” and in the prose of a hundred writers who have shared Shelley’s error without partaking of his genius, as the loveliest innocent ever martyred by the cruelty of hostile critics. But, in fact, the vituperations of Gifford and his crew were no more responsible for the death of Keats, than the stings of insects are for the death of a man who has perished of hunger on the coast of Labrador. They added to his sufferings, no doubt, but they did not take away his life. Keats had far too much virtue in the old Roman sense—far too much courage, to be killed by a criticism. He died of consumption, as he clearly and sadly knew that he was fated to do when he first saw the drop of arterial blood upon his pillow. Nor is it just, although it may seem generous, to estimate his fame chiefly by the anticipation of what he might have accomplished if he had lived longer; to praise him for his promise at the expense of his performance; and to rest his claim to a place among the English poets upon an uncertain prophecy of rivalry with Shakespeare. I find a far sounder note in Lowell’s manly essay, when he says: “No doubt there is something tropical and of strange overgrowth in his sudden maturity, but it was maturity nevertheless.” I hear the accent of a wiser and saner criticism in the sonnet of one of our American poets:
  • 74. “Touch not with dark regret his perfect fame, Sighing, ‘Had he but lived he had done so’; Or, ‘Were his heart not eaten out with woe John Keats had won a prouder, mightier name!’ Take him for what he was and did—nor blame Blind fate for all he suffered. Thou shouldst know Souls such as his escape no mortal blow— No agony of joy, or sorrow, or shame.” “Take him for what he was and did”—that should be the key-note of our thought of Keats as a poet. The exquisite harmony of his actual work with his actual character; the truth of what he wrote to what his young heart saw and felt and enjoyed; the simplicity of his very exuberance of ornament, and the naturalness of his artifice; the sincerity of his love of beauty and the beauty of his sincerity—these are the qualities which give an individual and lasting charm to his poetry, and make his gift to the world complete in itself and very precious, although,—or perhaps we should even say because,—it was unfinished. Youth itself is imperfect: it is impulsive, visionary, and unrestrained; full of tremulous delight in its sensations, but not yet thoroughly awake to the deeper meanings of the world; avid of novelty and mystery, but not yet fully capable of hearing or interpreting the still, small voice of divine significance which breathes from the simple and familiar elements of life. Yet youth has its own completeness as a season of man’s existence. It is justified and indispensable. Alfred de Musset’s “We old men born yesterday” are simply monstrous. The poetry which expresses and represents youth, the poetry of sensation and sentiment, has its own place in
  • 75. the literature of the world. This is the order to which the poetry of Keats belongs. He is not a feminine poet, as Mr. Coventry Patmore calls him, any more than Theocritus or Tennyson is feminine; for the quality of extreme sensitiveness to outward beauty is not a mark of femininity. It is found in men more often and more clearly than in women. But it is always most keen and joyous and overmastering in the morning of the soul. Keats is not a virile poet, like Dante or Shakespeare or Milton; that he would have become one if he had lived is a happy and loving guess. He is certainly not a member of the senile school of poetry, which celebrates the impotent and morbid passions of decay, with a café chantant for its temple, and the smoke of cigarettes for incense, and cups of absinthe for its libations, and for its goddess not the immortal Venus rising from the sea, but the weary, painted, and decrepit Venus sinking into the gutter. He is in the highest and best sense of the word a juvenile poet —“mature,” as Lowell says, but mature, as genius always is, within the boundaries and in the spirit of his own season of life. The very sadness of his lovely odes, “To a Nightingale,” “On a Grecian Urn,” “To Autumn,” “To Psyche,” is the pleasant melancholy of the springtime of the heart. “The Eve of St. Agnes,” pure and passionate, surprizing us by its fine excess of colour and melody, sensuous in every line, yet free from the slightest taint of sensuality, is unforgettable and unsurpassable as the dream of first love. The poetry of Keats, small in bulk and slight in body as it seems at first sight to be, endures, and will endure, in English literature, because it is the embodiment of the spirit of immortal youth. Here, I think, we touch its secret as an influence upon other poets. For that it has been an influence,—in the older sense of the word, which carries with it a reference to the guiding and controlling force supposed to flow from the stars to the earth,—is beyond all doubt. The History of English Literature, with which Taine amused us some fifty years ago, nowhere displays its narrowness of vision more
  • 76. egregiously than in its failure to take account of Gray, Collins, and Keats as fashioners of English poetry. It does not mention Gray and Collins at all; the name of Keats occurs only once, with a reference to “sickly or overflowing imagination,” but to Byron nearly fifty pages are devoted. The American critic, Stedman, showed a far broader and more intelligent understanding of the subject when he said that “Wordsworth begot the mind, and Keats the body, of the idyllic Victorian School.” We can trace the influence of Keats not merely in the conscious or unconscious imitations of his manner, like those which are so evident in the early poems of Tennyson and Procter, in Hood’s Plea of the Midsummer Fairies and Lycus the Centaur, in Rossetti’s Ballads and Sonnets, and William Morris’s Earthly Paradise, but also in the youthful spirit of delight in the retelling of old tales of mythology and chivalry; in the quickened sense of pleasure in the luxuriance and abundance of natural beauty; in the freedom of overflowing cadences transmuting ancient forms of verse into new and more flexible measures; in the large liberty of imaginative diction, making all nature sympathize with the joy and sorrow of man,—in brief, in many of the finest marks of a renascence, a renewed youth, which characterize the poetry of the early Victorian era. I do not mean to say that Keats alone, or chiefly, was responsible for this renascence. He never set up to lead a movement or to found a school. His genius is not to be compared to that of a commanding artist like Giotto or Leonardo or Michelangelo, but rather to that of a painter like Botticelli, whose personal and expressive charm makes itself felt in the work of many painters, who learned secrets of grace and beauty from him, though they were not his professed disciples or followers. Take for example Matthew Arnold. He called himself, and no doubt rightly, a Wordsworthian. But it was not from Wordsworth that he caught the strange and searching melody of “The Forsaken Merman,” or learned to embroider the laments for “Thyrsis” and “The Scholar-Gypsy” with such opulence of varied bloom as makes
  • 77. Welcome to Our Bookstore - The Ultimate Destination for Book Lovers Are you passionate about books and eager to explore new worlds of knowledge? At our website, we offer a vast collection of books that cater to every interest and age group. From classic literature to specialized publications, self-help books, and children’s stories, we have it all! Each book is a gateway to new adventures, helping you expand your knowledge and nourish your soul Experience Convenient and Enjoyable Book Shopping Our website is more than just an online bookstore—it’s a bridge connecting readers to the timeless values of culture and wisdom. With a sleek and user-friendly interface and a smart search system, you can find your favorite books quickly and easily. Enjoy special promotions, fast home delivery, and a seamless shopping experience that saves you time and enhances your love for reading. Let us accompany you on the journey of exploring knowledge and personal growth! ebookgate.com