//------------------------------------------------------------------------ bool CCheckBox::getFocusPath (CGraphicsPath& outPath) { if (wantsFocus ()) { CCoord focusWidth = getFrame ()->getFocusWidth (); CRect checkBoxSize (getViewSize ()); if (getDrawBackground ()) { checkBoxSize.setWidth (getDrawBackground ()->getWidth ()); checkBoxSize.setHeight (getDrawBackground ()->getHeight () / 6); } else { checkBoxSize.setHeight (getFontCapHeight (font) + 2); checkBoxSize.setWidth (checkBoxSize.getHeight ()); checkBoxSize.offset (1, ceil ((getViewSize ().getHeight () - checkBoxSize.getHeight ()) / 2)); } outPath.addRect (checkBoxSize); checkBoxSize.inset (-focusWidth, -focusWidth); outPath.addRect (checkBoxSize); } return true; }