List of Pen API Functions
The following tables list by category all functions in version 2.0 of the Pen API. Functions appear in alphabetical order within each category, together with a brief description.| System and hardware functions
| Description
|
| GetPenAsyncState
| Gets state of pen barrel button.
|
| GetPenMiscInfo
| Gets current system settings.
|
| GetVersionPenWin
| Gets the Pen API version number.
|
| SetPenMiscInfo
| Sets system defaults and assumptions.
|
| UpdatePenInfo
| Called by the pen driver to notify the system of a change in the driver
configuration.
|
| Display functions
| Description
|
| CreatePenDataRegion
| Returns a screen region that contains the points of an HPENDATA object.
|
| DrawPenDataEx
| Enhanced version of DrawPenData.
|
| DrawPenDataFmt
| Default version of DrawPenDataEx.
|
| RedisplayPenData
| Displays collected pen data exactly as originally drawn.
|
| ShowKeyboard
| Displays or hides the on-screen keyboard.
|
| StartInking
| Begins the process of leaving a visible ink trail
as the pen moves. See the descriptions of StartPenInput and DoDefaultPenInput. |
| StopInking
| Stops the inking process begun by a call to StartInking.
|
| Pen data functions
| Description
|
| AddPenDataHRC
| Adds an HPENDATA object to an HRC.
|
| AddPointsPenData
| Adds new points and original equipment manufacturer (OEM) data to an existing HPENDATA object.
|
| CreatePenData
| Allocates memory for a new HPENDATA object and initializes its header.
|
| CreatePenDataEx
| Enhanced version of CreatePenData.
|
| CreatePenDataHRC
| Returns handle to HPENDATA object associated with an HRC.
|
| DestroyPenData
| Frees memory occupied by an HPENDATA memory block.
|
| DuplicatePenData
| Clones an existing HPENDATA object.
|
| ExtractPenDataPoints
| Copies or removes points from a stroke.
|
| ExtractPenDataStrokes
| Copies or removes selected strokes, optionally creating a new HPENDATA object from the copied strokes.
|
| GetPenDataAttributes
| Retrieves information about an HPENDATA object.
|
| GetPenDataInfo
| Gets status information for an HPENDATA object.
|
| GetPointsFromPenData
| Returns an array of points from an HPENDATA object.
|
| GetStrokeAttributes
| Retrieves information about a stroke.
|
| GetStrokeTableAttributes
| Retrieves information about a stroke's class.
The class is an entry in a table stored in the PENDATAHEADER structure. |
| InsertPenData
| Combines two HPENDATA blocks.
|
| InsertPenDataPoints
| Inserts points into a stroke in an HPENDATA object.
|
| InsertPenDataStroke
| Inserts data for a new stroke into an existing HPENDATA object.
|
| OffsetPenData
| Offsets pen data points by a specified amount.
|
| PenDataFromBuffer
| Reverse of PenDataToBuffer, which must be called first. Creates an HPENDATA block and writes the buffer back into it.
|
| PenDataToBuffer
| Serializes the contents of an HPENDATA block to a buffer.
|
| RemovePenDataStrokes
| Removes specified strokes from an HPENDATA object.
|
| ResizePenData
| Scales ink data to fit a specified rectangle.
|
| SetStrokeAttributes
| Sets attributes of a stroke. Reverse of GetStrokeAttributes.
|
| SetStrokeTableAttributes
| Sets attributes for a stroke's class. Reverse of GetStrokeTableAttributes.
|
| Recognition functions
| Description
|
| AddPenInputHRC
| Adds raw pen input to an HRC object.
|
| AddWordsHWL
| Adds words to a word list.
|
| ConfigRecognizer
| System access to recognizer configuration. Applications should not call this
function.
|
| CreateCompatibleHRC
| Creates an empty HRC object.
|
| CreateHWL
| Creates a word list.
|
| DestroyHRC
| Destroys a recognizer's recognition context object.
|
| DestroyHRCRESULT
| Destroys a recognizer's results object.
|
| DestroyHWL
| Destroys the word list handle created by CreateHWL and frees its memory.
|
| EnableGestureSetHRC
| Enables or disables recognition of specified gestures.
|
| EnableSystemDictionaryHRC
| Specifies whether a recognizer should use its dictionary.
|
| EndPenInputHRC
| Informs a recognizer that the input session has ended.
|
| GetAlphabetHRC
| Retrieves the current alphabet from a recognizer.
|
| GetAlphabetPriorityHRC
| Retrieves the current alphabet priority from a recognizer.
|
| GetAlternateWordsHRCRESULT
| Gets alternative guesses made by a recognizer.
|
| GetBoxMappingHRCRESULT
| Retrieves from a recognizer the locations of a range of symbols in boxes.
|
| GetBoxResultsHRC
| Gets recognition results for a range of boxes.
|
| GetGuideHRC
| Gets a copy of the GUIDE structure (if any) in an HRC object.
|
| GetHotspotsHRCRESULT
| Returns the hot spots for a specified gesture.
|
| GetHRECFromHRC
| Gets module handle of recognizer from an HRC.
|
| GetMaxResultsHRC
| Gets the maximum number of guesses a recognizer can make.
|
| GetResultsHRC
| Retrieves an HRCRESULT object from recognizer containing recognition results.
|
| GetWordlistCoercionHRC
| Gets the current degree of influence a word list or dictionary has on
recognition confidence levels.
|
| GetWordlistHRC
| Gets a word list from an HRC object.
|
| InstallRecognizer
| Loads a specified recognizer.
|
| ProcessHRC
| Tells recognizer to process input for a given period of time.
|
| ReadHWL
| Reads a word list from a file.
|
| SetAlphabetHRC
| Specifies the alphabet for a recognition session.
|
| SetAlphabetPriorityHRC
| Specifies alphabet priority for a session.
|
| SetBoxAlphabetHRC
| Specifies the alphabet for a range of boxes.
|
| SetGuideHRC
| Specifies guides for an HRC.
|
| SetMaxResultsHRC
| Sets the maximum number of guesses a recognizer can make.
|
| SetWordlistCoercionHRC
| Sets the degree of influence a word list or dictionary has on recognition
confidence levels.
|
| SetWordlistHRC
| Identifies a word list for an HRC object.
|
| TrainHREC
| Passes ink and correct interpretations to recognizer for training.
|
| UninstallRecognizer
| Unloads a specified recognizer.
|
| WriteHWL
| Writes a word list to a file.
|
| Symbol manipulation functions
| Description
|
| CharacterToSymbol
| Converts an ANSI string to an array of symbol values.
|
| EnumSymbols
| Enumerates symbol strings in a symbol graph.
|
| FirstSymbolFromGraph
| Returns the array of symbols that is the most likely interpretation of a
specific symbol graph.
|
| GetSymbolCount
| Returns the number of symbol strings contained in the symbol graph.
|
| GetSymbolCountHRCRESULT
| Gets the number of symbol values in results.
|
| GetSymbolMaxLength
| Gets the length of the longest symbol string contained in the symbol graph.
|
| GetSymbolsHRCRESULT
| Gets symbol values of recognition results.
|
| SymbolToCharacter
| Converts an array of symbols to an ANSI string.
|
| Time interval functions
| Description
|
| AddInksetInterval
| Adds an INTERVAL structure to an existing HINKSET object.
|
| CreateInkset
| Creates an empty inkset into which intervals can be added with the AddInksetInterval function.
|
| CreateInksetHRCRESULT
| Retrieves the intervals for a specified series of symbols returned by the
recognizer.
|
| DestroyInkset
| Frees memory occupied by an inkset and invalidates the HINKSET handle.
|
| GetInksetInterval
| Copies a series of intervals from an HINKSET object to an array of INTERVAL structures.
|
| GetInksetIntervalCount
| Returns the number of intervals in an HINKSET object.
|
| Compression functions
| Description
|
| CompressPenData
| Compresses and uncompresses data.
|
| DPtoTP
| Converts display coordinates to tablet coordinates.
|
| MetricScalePenData
| Converts pen data points to one of the supported metric modes.
|
| TPtoDP
| Converts tablet coordinates to display coordinates.
|
| TrimPenData
| Removes selected data from an HPENDATA block.
|
| Utility functions
| Description
|
| AtomicVirtualEvent
| Blocks out physical pen events while posting virtual events.
|
| BoundingRectFromPoints
| Returns the bounding rectangle of an array of points.
|
| ConfigHREC
| Configures or queries recognizer options.
|
| CorrectWriting
| Displays lens or Correct Text dialog box to allow user to correct text.
|
| CorrectWritingEx
| Sends text to the CorrectText dialog box to allow the user to edit text using
the Japanese Data Input Window. (Japanese version only.)
|
| DoDefaultPenInput
| Runs high-level recognition/data collection. Internally calls StartPenInput, StartInking, StopPenInput, and StopInking.
|
| GetPenAppFlags
| Returns the task flags created by SetPenAppFlags.
|
| GetPenInput
| Collects input data as the user writes.
|
| GetPenResource
| Retrieves a copy of the pen services resource. (Japanese version only.)
|
| HitTestPenData
| Determines whether a given point lies near a stroke.
|
| IsPenEvent
| Determines whether a WM_LBUTTONDOWN message is generated by a mouse or pen
device.
|
| KKConvert
| (Japanese version only.) Activates the Kana-to-Kanji converter.
|
| PeekPenInput
| Retrieves information about a pen packet in the pen input queue. This function
is similar to GetPenInput, but does not remove the pen packet from the queue.
|
| PostVirtualKeyEvent
| Simulates a keystroke by sending a virtual key code to Windows.
|
| PostVirtualMouseEvent
| Simulates mouse activity by sending a virtual mouse event to Windows.
|
| SetPenAppFlags
| Sets pen flags for the application that are used globally by the pen services.
|
| StartPenInput
| Begins collecting into an internal buffer ink
data generated by the moving pen. See also the descriptions of . DoDefaultPenInput and StartInking. |
| StopPenInput
| Ends collection process begun by a call to StartPenInput.
|
| TargetPoints
| Determines the logical recipient of data among several targets.
|
| Hook functions
| Description
|
| SetPenHook
| Sets or removes a hook for capturing low-level pen events.
|
| SetResultsHookHREC
| Sets a hook for recognition results.
|
| UnhookResultsHookHREC
| Unhooks a hook set by SetResultsHookHREC.
|
| Obsolete functions
| Description
|
| BeginEnumStrokes
| Locks an HPENDATA memory block in global memory in preparation for reading.
|
| CloseRecognizer
| Called by the system when uninstalling a
recognizer. Subfunction has been superseded by WCR_CLOSERECOGNIZER in ConfigRecognizer. |
| CompactPenData
| Data compression function superseded by CompressPenData and TrimPenData.
|
| DictionarySearch
| Searches dictionary for a word or phrase.
|
| DrawPenData
| Displays ink according to a display context HDC. Superseded by DrawPenDataEx.
|
| EmulatePen
| Emulates a pen system.
|
| EndEnumStrokes
| Unlocks an HPENDATA memory block. Required after calling BeginEnumStrokes.
|
| GetGlobalRC
| Retrieves a copy of the current system RC structure.
|
| GetPenDataStroke
| Gets the raw data for a stroke stored in an HPENDATA memory block.
|
| GetPenHwEventData
| Retrieves a range of pen event data from the internal pen data buffer.
|
| InitRC
| Initializes recognition context for the recognizer. Only for compatibility
with version 1.0.
|
| InitRecognizer
| Called by the system when it installs a recognizer. Superseded by
WCR_INITRECOGNIZER subfunction in ConfigRecognizer.
|
| IsPenAware
| Checks application's capability to handle pen events. Superseded by GetPenAppFlags.
|
| ProcessWriting
| Runs high-level recognition services. Superseded by DoDefaultPenInput.
|
| Recognize
| Begins recognition for a version 1.0 recognizer.
|
| RecognizeData
| Delayed recognition for a version 1.0 recognizer.
|
| RegisterPenApp
| Identifies an application to the system as pen-aware. Superseded by SetPenAppFlags.
|
| SetGlobalRC
| Sets default settings for the specified recognition context. This function
should be called only from the pen Control Panel program.
|
| SetRecogHook
| Installs and removes a recognition hook in version 1.0. Superseded by SetResultsHookHREC.
|
| TrainContext
| Passes to the recognizer a previous recognition result that may contain errors
along with the required interpretation.
|
| TrainContextInternal
| Called by system when an application calls TrainContext.
|
| TrainInk
| Informs the recognizer at the DLL recognition level that the raw data input
represents the symbol value results.
|
| TrainInkInternal
| Called by system when an application calls TrainInk.
|
- Software for developers
-
Delphi Components
.Net Components
Software for Android Developers - More information resources
-
MegaDetailed.Net
Unix Manual Pages
Delphi Examples


