Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Adds an entry to the glyph table, which specifies images to display for specific tags in design mode.
HRESULT AddToGlyphTable( 
   LPCTSTR szTag, 
   LPCTSTR szImgUrl, 
   unsigned short nTagType, 
   unsigned short nAlignment, 
   unsigned short nPosInfo, 
   unsigned short nDirection, 
   unsigned int nImgWidth, 
   unsigned int nImgHeight  
) const;
Parameters
- szTag 
 The tag name (for example, "P" or "table").
- szImgUrl 
 The image URL.
- nTagType 
 Tag type: 0 means the image is for the opening tag only. 1 means the image is for the closing tag only. 2 means the image is for both the opening and closing tags. Single tags such as br and comment must be added with the tag type set to 0.
- nAlignment 
 Alignment (rectangular elements only): This parameter indicates that the image is for an element with an alignment attribute. Left = 0, center = 1, right = 2, and undefined = 3. Left, right, or center attributes must be explicitly set on the element.
- nPosInfo 
 Positioning information. Determines what cascading style sheets (CSS) positioning value the glyph applies to, where static positioning = 0, absolute positioning = 1, relative positioning = 2, and all = 3. This field enables you to specify one glyph for a tag when it is not positioned and another glyph to show an anchor point when the tag is positioned.
- nDirection 
 The direction. This parameter specifies the image for a tag based on the reading order of the current language. 0 specifies left to right, 1 specifies right to left, 2 specifies top to bottom, 3 specifies bottom to top, and 4 specifies all. You normally set this field to 4.
- nImgWidth 
 The image width in pixels.
- nImgHeight 
 The image height in pixels.
Return Value
Returns S_OK on success, or an error HRESULT on failure.
Remarks
For more information on the parameters, see "Glyph Table String Format" in Using Editing Glyphs.
This method sends the IDM_ADDTOGLYPHTABLE command ID to the WebBrowser control.
Requirements
Header: afxhtml.h