Extending selection
Posted: Wed Sep 03, 2008 1:44 pm
Assume that the editor has text/figures consisting of start_item, middle_item1, middle_item2, ..., middle_itemN, end_item. What I need is that whenever any part of any of those item is selected, all of them are selected. (Ideally, I would prefer treating all those items as a single block, but it does not seem to be possible since they are of different styles and they may be separated by line breaks.)
I can do that by calling SetSelectionBounds in OnSelect but that creates another OnSelect event. I can, of course, avoid infinite loop by recognizing the second time that Selection Bounds are already as desired, but it sounds like a kludge.
I can do that by calling SetSelectionBounds in OnSelect but that creates another OnSelect event. I can, of course, avoid infinite loop by recognizing the second time that Selection Bounds are already as desired, but it sounds like a kludge.