Longhorn Search and Organize User And Developer Experience Paul Cutsinger – Lead Program Manager Kerem Karatal – Lead Program Manager Microsoft Corporation Agenda Demo Overview Extending The Longhorn Explorer Developing Applications Search, Organize And Visualize Paul Cutsinger Lead Program Manager Developer Experience Extending the Longhorn Explorer: Content (metadata and full-text) Rich thumbnails Rich previews Developing applications using new APIs: Search in your application Read/Write metadata Leverage Common File Dialog Architecture Overview 3rd Party Applications Windows Explorer Windows Search Engine Windows Metadata System 3rd Party System Custom Properties Properties System Metadata Handlers 3rd Party Metadata Handlers File System (NTFS, FAT32) System Protocol Handlers 3rd Party Protocol Handlers Other Data Stores Agenda Demo Overview Extending The Longhorn Explorer Developing Applications Extending Longhorn Explorer Top 3 Extension Points Provide content to the Explorer: Search across file formats, data stores. Both full-text content & metadata. Enable organization by writing metadata back into file formats. E.g.: Set System.Keyword property on .foo file type. Provide rich thumbnails in the Explorer: Visually stimulating view of files in the Explorer. Provide rich previewing in the Explorer: Browse contents of files without opening the file. Providing Content 3 Ways To Provide Content Property Handlers File formats Metadata Some full-text content Multimedia File Formats Property Handlers + IFilters (Full-text) File formats Metadata Extensive full-text content, multilingual chunks Document-based File Formats Protocol Handlers Non-file system based stores Metadata Extensive full-text content, multilingual chunks Document Management, Messaging Metadata Leverage system properties where possible: Best performance Best behavior in heterogeneous sets E.g. One column shows Photographer and Author in Explorer Otherwise add new properties: XML based format for describing custom properties, APIs to register the custom properties to system. Property naming convention: Canonical Names: Publisher.ApplicationName.PropertyName FormatId/PropertyId: FormatId: Use a new GUID for each property PropertyId: Use value > 2 Custom Properties <configuration xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation= "allprops.xsd“ > <propertyDescriptionList publisher = "Microsoft" product = "Windows” > <propertyDescription name="System.Author" formatId="F29F85E0-4FF9-1068-AB91-08002B27B3D9" propertyId="4"> <typeInfo type="String" canStackBy="true" groupingRange=“Discrete" multipleValues="true" isReadOnly="false"/> <displayInfo drawControl=“Explorer.EditPropertyControl” editControl=“Explorer.EditPropertyControl"> </displayInfo> <labelInfo label="Author" invitationText="Add an author" sortDescription="AToZ"/> </propertyDescription> <propertyDescriptionList/> </configuration> Providing Metadata For File Formats Property Handlers Registered through the File Association System One per file type Can be invoked as: Read-Only while indexing files Read/Write when reading/updating metadata in the Explorer Implemented as COM components Mainly implement: IInitializeWithStream – Initialization code IPropertyStore – Property Read/Write access IPropertyStoreCapabilities – Indicate capabilities like set of properties supported, read/write etc. Rich Thumbnails In Longhorn In Longhorn, thumbnails provide a rich visualization option for file types: Providing Rich Thumbnails Longhorn is introducing a new and simpler API. IThumbnailProvider replaces IExtractImage There are problems with existing API: Complex and error-prone implementation: Many unused flags, parameters. Need for fixing many bitmaps that are returned: Convert bit depth to 32bpp, Stretch if necessary, Guess if bitmap is RGB or ARGB. Opportunity to open files with too many or wrong oplocks. Thumbnail handlers are now required to implement: IInitializeWithStream – Initialization code. IThumbnailProvider – Simpler interface for providing thumbnails. Rich Previews In Explorer A new pane in Explorer : Reading Pane In place browsing of file contents Providing Rich Preview Handlers 3rd parties provide viewers for their own file formats Will run in: Explorer Outlook 12 and Common File Dialog Implemented as COM components. Light weight components that render content in readonly mode Mainly implement: IInitializeWithStream – Initialization code IPreviewHandler – Rendering and interactive code Agenda Demo Overview Extending The Longhorn Explorer Developing Applications Developing Applications New Set Of APIs Known Folders: Common namespace locations E.g. Documents, Music, etc. Access them and create new ones Search in your application: Query items in Windows Search Engine Metadata Read/Write: Unified access to file formats. Common File Dialog: Open/save files with metadata Known Folders Longhorn defines a new and more intuitive namespace: Users Username Documents Pictures Music … Public Documents … Redirection to common network locations: In XP, known as “Redirected My Documents” In Longhorn available for all known folders Known Folders Using And Extending Applications should NEVER hard code file paths Use Known Folder APIs instead Use existing Known Folders if they are semantically equivalent: E.g.: PDF documents stored in Documents Otherwise applications can create new known folders: E.g.: 3D Drawings, Shapes, Code Projects etc. Using Search In Applications OLEDB/ADO APIs are used for issuing queries SQL-like syntax Returns an OLEDB Recordset Both managed and native access Columns correspond to properties in Windows Metadata System E.g.: System.Photo.FNumber Reading/Writing Properties Unified layer to read/write metadata into files formats: Requires metadata handlers which provide per file type handling 3rd party applications can: Enumerate properties stored in a file Discover property descriptions as described in the system Read and write values for properties Common File Dialog Longhorn Common File Dialog mirrors the familiar Explorer UI: Using Common File Dialog New COM APIs. Enable multiple view states per application View State: Last visited folder, dialog size Working with properties: Promote application related properties Setting default values for properties Getting property values to save Rich set of events: FileOk, Help, SelectionChange, FolderChange, Overwrite, etc. Extending Common File Dialog New Places In Places Bar Extending Common File Dialog Custom Layout And Controls Summary Longhorn provides 3 ways to extend Search, Organize and Visualize experience: Providing content (metadata and full-text) Providing rich thumbnails Providing rich preview handlers Longhorn enables application developers: Use and extend Known Folders Issue queries to Windows Search Engine Read/Write properties through unified layer Incorporate the new UI using the Common File Dialog © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.