DCPUSHBUTTONXP, build 255
Posted: Tue Apr 03, 2012 9:48 am
				
				Hi, Roger.
If the pushbutton image is an icon object, DC_XbpPushButtonXP:Draw() runs into an error here (around line 1135):
The method "draw" has different parameters for icons. It should be this way:
Anyway, there seem to be some other cosmetic problems; I'm currently investigating this.
1. If a button has an image and a text caption, the text caption is one pixel higher as it should be.
2. Tooltips and hotkeys seem not to work with the BUTTONS clause of DCGET OPTIONS (items 9 and 10 of the buttons array).
			If the pushbutton image is an icon object, DC_XbpPushButtonXP:Draw() runs into an error here (around line 1135):
Code: Select all
  ELSEIF Valtype( cCaption ) == 'O' .AND. (cCaption:isDerivedFrom('XbpBitMap') .OR. cCaption:isDerivedFrom('XbpIcon'))
    oBitmap := cCaption
    aSource := {0,0,oBitmap:xSize,oBitmap:ySize}
    aTarget := { nStartCol, nStartRow, nEndCol, nEndRow }
    oBitmap:draw( oPS, aTarget, aSource, ;
            IIF(lDisabled .AND. ::disabledBmp,GRA_BLT_ROP_PATCOPY,nil), GRA_BLT_BBO_IGNORE )   // abo serviceCode: Select all
ELSEIF Valtype( cCaption ) == 'O' .AND. (cCaption:isDerivedFrom('XbpBitMap') .OR. cCaption:isDerivedFrom('XbpIcon'))
    oBitmap := cCaption
    aSource := {0,0,oBitmap:xSize,oBitmap:ySize}
    aTarget := { nStartCol, nStartRow, nEndCol, nEndRow }
    IF cCaption:isDerivedFrom('XbpIcon') // new
      oBitmap:draw( oPS, aTarget,IIF(lDisabled .AND. ::disabledBmp,XBP_STATE_DISABLED,XBP_STATE_NORMAL) )
      ELSE
      oBitmap:draw( oPS, aTarget, aSource, ;
            IIF(lDisabled .AND. ::disabledBmp,GRA_BLT_ROP_PATCOPY,nil), GRA_BLT_BBO_IGNORE )   // abo service
    ENDIF1. If a button has an image and a text caption, the text caption is one pixel higher as it should be.
2. Tooltips and hotkeys seem not to work with the BUTTONS clause of DCGET OPTIONS (items 9 and 10 of the buttons array).