ADDFRAMEDLGPARAMS

typedef struct _ADDFRAMEDLGPARAMS 
{
   L_UINT uStructSize ;
   pBITMAPHANDLE pBitmap ;
   L_BOOL bZoomToFit ; 
   L_BOOL bKeepFrameState;
   L_BOOL bUseMask;
   COLORREF crMask;
   BYTE SmoothEdge;
   L_INT nLocation;
   L_INT nQuality;
   LPDLGBITMAPLIST pBitmapList ;
   L_INT nFrameBitmapIndex ;
   L_UINT32 uDlgFlags ; 
   LTCOMMDLGHELPCB pfnHelpCallback ; 
   L_VOID  *pHelpCallBackUserData ;
} ADDFRAMEDLGPARAMS, * LPADDFRAMEDLGPARAMS ;

The ADDFRAMEDLGPARAMS structure provides information used to initialize the dialog box created by the LDialogImage::DoModalAddFrame function. After the user closes the dialog box, this structure is updated with information about the user's selections.

Member

Description

uStructSize

Size of this structure, in bytes. Use the sizeof operator to calculate this value.

pBitmap

Ignored.

bZoomToFit

Flag that indicates the initial zoom level for previewing the image. Possible values are:

 

Value

Meaning

 

TRUE

Set the initial zoom level to "Zoom to fit".

 

FALSE

Set the initial zoom level to "Normal (1:1)".

bKeepFrameState

Flag that indicates the state of the frame bitmap. This flag is only used as an input and only when you called the LDialogBase::EnableAutoProcess. Possible values are:

 

Value

Meaning

 

TRUE

Keep the state of the frame bitmap and operate on a copy of the frame bitmap.

 

FALSE

Work on the original frame bitmap so this bitmap may be resized during the LBitmap::AddFrame function.

bUseMask

Flag that indicates whether to force the bitmap to be put on a specific region of the frame bitmap. Set this to indicate the initial value for the dialog. This member will be updated based on whether the Use Mask check box in the dialog is checked or cleared. Possible values are:

 

Value

Meaning

 

TRUE

Select a region on the frame bitmap with the same color specified in crMask and place the bitmap in this region.

 

FALSE

Put the bitmap in the center of the frame bitmap. This is the default value.

 

crMask

The COLORREF value that specifies the masking color to use when bUseMask is set to TRUE. Set this to indicate the initial value for the dialog. This member will be updated with the color selected in the dialog.

SmoothEdge

Value that indicates the amount to smooth the edge between the frame and the original bitmap. This value is used only when bUseMask is set to FALSE. Valid values range from 0 to 255. Set this to indicate the initial value for the dialog. This member will be updated with the value entered in the Tolerance box in the dialog.

nLocation

Flag that indicates the location of the frame with respect to the bitmap. Set this to indicate the initial value for the dialog. This member will be updated with the value entered in the Placement Combo box in the dialog. Possible values are:

 

Value

Meaning

 

FRAME_INSIDE

[0] The frame will be within the original bitmap. This is the default.

 

FRAME_OUTSIDE

[1] The frame will be outside the original bitmap.

nQuality

Flag that specifies the quality of the resulting bitmap. Set this to indicate the initial value for the dialog. This member will be updated with the value entered in the Quality combo box in the dialog. Possible values are:

 

Value

Meaning

 

FRAME_QUALITY_LOW

[0] Give the resulting bitmap normal quality.

 

FRAME_QUALITY_HIGH

[1] Give the resulting bitmap high quality.

 

pBitmapList

Pointer to a DLGBITMAPLIST structure that is used to initialize the image picker in the dialog. The bitmap list should contain frame bitmaps, which are used to preview the add frame effect. For more information, refer to LBitmap::AddFrame . The pszDescription member of the DLGBITMAPLIST structure will be used as a tool tip for each image in the image picker, when the mouse hovers over it.

nFrameBitmapIndex

Index of the frame bitmap to use from the image picker. This is an index into the pBitmapList member. Set this before calling LDialogImage::DoModalAddFrame to indicate the initial value for the image picker. This member will be updated to the frame image selected in the image picker.

uDlgFlags

User interface flags for this dialog, which determine the layout and action of the dialog. Possible values are:

 

Value

Meaning

 

DLG_ADDFRAME_SHOW_CONTEXTHELP

[0x00000002] Dialog should contain a context sensitive help icon.

 

DLG_ADDFRAME_SHOW_TOOL_COLORPICKER

[0x00000010] Show the Color button.

 

DLG_ADDFRAME_SHOW_APPLY

[0x00000100] Show the Apply button in the dialog. The dialog will not apply any effect unless the user presses the Apply button.

pfnHelpCallback

Ignored.

pHelpCallBackUserData

Ignored.