@Override
        public void widgetSelected(SelectionEvent e)
        {
            if (!dragging)
                return;

            //boolean selection = startPosition != endPosition;
            int lower = e.x / charLen;
            int higher = e.y / charLen;
            int caretPos = ((StyledText) e.widget).getCaretOffset() / charLen;
            caretStickToStart = caretPos < higher || caretPos < lower;
            if (lower > higher) {
                lower = higher;
                higher = e.x / charLen;
            }

            select(textAreasStart + lower, textAreasStart + higher);
//            if (selection != (startPosition != endPosition))
//                notifyListeners(SWT.Modify, null);

            redrawTextAreas(false);
        }
Converts a hex String to byte[]. Will convert full bytes only, odd number of hex characters will
have a leading '0' added. Big endian.

@param hexString an hex string (ie. "0fdA1").
@return the byte[] value of the hex string
plugins/org.jkiss.dbeaver.ui.editors.hex/src/org/jkiss/dbeaver/ui/editors/binary/HexEditControl.java