long incrementPosWithinLimits(long oldPos, boolean countNibbles)
    {
        if (oldPos < content.length())
            if (countNibbles) {
                if (upANibble > 0) ++oldPos;
                upANibble ^= 1;  // 1->0, 0->1
            } else {
                ++oldPos;
            }

        return oldPos;
    }
Gets the selection start and end points as long values

@return 2 elements long array, first one the start point (inclusive), second one the end point
        (exclusive)
plugins/org.jkiss.dbeaver.ui.editors.hex/src/org/jkiss/dbeaver/ui/editors/binary/HexEditControl.java