Jump to content

CM SETRECORDEMPHASIS: Difference between revisions

From EDM2
Created page with "This message sets the emphasis attributes of the specified container record. ==Syntax== <PRE> param1 PRECORDCORE pRecord; Pointer to the specified container record.: param2 USHORT usChangeEmphasis; Change-emphasis-attribute flag.: USHORT fEmphasisAttribute; Emphasis attribute of the container record.: </PRE> ;Note:; If the CCS_MINIRECORDCORE style bit is specified when a container is created, then MINIRECORDCORE should be used instead of ..."
 
No edit summary
 
Line 11: Line 11:
;Note:; If the CCS_MINIRECORDCORE style bit is specified when a container is created, then [[MINIRECORDCORE]] should be used instead of [[RECORDCORE]], and PMINIRECORDCORE should be used instead of PRECORDCORE in all applicable data structures and messages.
;Note:; If the CCS_MINIRECORDCORE style bit is specified when a container is created, then [[MINIRECORDCORE]] should be used instead of [[RECORDCORE]], and PMINIRECORDCORE should be used instead of PRECORDCORE in all applicable data structures and messages.
==Parameters==
==Parameters==
;pRecord ([[PRECORDCORE]]) - Input
;pRecord (P[[RECORDCORE]]) - Input
: Pointer to the specified container record.
: Pointer to the specified container record.
;usChangeEmphasis ([[USHORT]]) - Input
;usChangeEmphasis ([[USHORT]]) - Input

Latest revision as of 01:57, 21 April 2025

This message sets the emphasis attributes of the specified container record.

Syntax

param1
PRECORDCORE pRecord;          /* Pointer to the specified container record. */

param2
USHORT usChangeEmphasis;   /* Change-emphasis-attribute flag. */
USHORT fEmphasisAttribute; /* Emphasis attribute of the container record. */
Note
; If the CCS_MINIRECORDCORE style bit is specified when a container is created, then MINIRECORDCORE should be used instead of RECORDCORE, and PMINIRECORDCORE should be used instead of PRECORDCORE in all applicable data structures and messages.

Parameters

pRecord (PRECORDCORE) - Input
Pointer to the specified container record.
usChangeEmphasis (USHORT) - Input
Change-emphasis-attribute flag:
TRUE: The container record's emphasis attribute is to be set ON if the change specified is not the same as the current state.
FALSE: The container record's emphasis attribute is to be set OFF if the change specified is not the same as the current state.
fEmphasisAttribute (USHORT) - Input
Emphasis attribute of the container record. The following states can be combined by using a logical OR operator (|):
CRA_CURSORED: Specifies that a record will be drawn with a selection cursor.
CRA_DISABLED: Specifies that a record will be drawn with unavailable-state emphasis.
CRA_INUSE: Specifies that a record will be drawn with in-use emphasis.
CRA_PICKED: Specifies that the container record will be picked up as part of the drag set.
CRA_SELECTED: Specifies that a record will be drawn with selected-state emphasis.
CRA_SOURCE: Specifies that a record will be drawn with source-menu emphasis.

Returns

rc (BOOL) - returns
Success indicator.
TRUE: Successful completion.
FALSE: An error occurred. The WinGetLastError function may return the following errors:
PMERR_INVALID_PARAMETERS (1208)
PMERR_INSUFFICIENT_MEMORY (203E)

Remarks

For single-selection containers, the selection of the previous container record is cancelled before another record is selected. The selection cursor is set with the CRA_CURSORED attribute for single-selection containers. Only one selection cursor is allowed.

The selection cursor must always be available to the user. Therefore, if you attempt to disable the selection cursor by specifying FALSE for the usChangeEmphasis parameter and CRA_CURSORED for the fEmphasisAttribute parameter, the PMERR_INVALID_PARAMETERS error is set. In order to change the selection cursor attribute, TRUE should be specified for the usChangeEmphasis parameter and CRA_CURSORED for the fEmphasisAttribute parameter. The pRecord parameter should point to the record to which the selection cursor should be applied. The container control removes the selection cursor from the record with the cursor and applies it to the new record.

A CN_EMPHASIS notification code is sent to the container owner if the record emphasis attribute is changed.

Default Processing

The default window procedure does not expect to receive this message and therefore takes no action on it other than to return FALSE.