@Override
    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
        measureChildren(widthMeasureSpec, heightMeasureSpec);
        int widthSize = mWidth + getPaddingLeft() + getPaddingRight();
        int heightSize = mWidth + getPaddingTop() + getPaddingBottom();
        //This diff is the basic calculation of the difference between
        //a square side size and its diagonal
        //this helps us account for the visual offset created by MarkerDrawable
        //when leaving one of the corners un-rounded
        int diff = (int) ((1.41f * mWidth) - mWidth) / 2;
        setMeasuredDimension(widthSize, heightSize + diff + mSeparation);
    }
This is a BalloonMarker used to {@link SeekBar}
<p>
<p><strong>XML attributes</strong></p>
<p>
See {@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gFont Attributes},
{@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gMarkerBackgroundColor Attributes},
{@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gMarkerElevation Attributes}
{@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gMarkerSeparation Attributes}
{@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gMarkerTextAppearance Attributes}
{@link net.qiujuer.genius.ui.R.styleable#BalloonMarker_gMarkerTextPadding Attributes}
caprice/ui/src/main/java/net/qiujuer/genius/ui/widget/BalloonMarker.java