Hi, Thanks to the help of Frank, I've completed this feature in a fashion. Thank you very much.
On Tue, 16 Sep 2008 08:39:04 +0200 Frank Meies <[EMAIL PROTECTED]> wrote: > Hi, > > On 15.09.08 21:25, Takashi Nakamoto wrote: > > > > I filed issue 93924 with a proposal patch related to this matter. > > However, I left a problem that the patch cannot trigger reconversion > > in a conditions, and I have a relevant question. > > > > That is the condition that Writer has multiple selection. In this > > case, before reconversion process, Writer should cancel all selection > > except one selection that was selected last (in this case, "last" is > > used in terms of time, not position). I'd like to know what code can > > realize this behavior. I sought related classes and methods through > > sw project, but I couldn't find a good solution. Please let me know > > any idea or hint. > > I think pCurCrsr of the shell always points to the 'last' selection. I > assigned this issue to Oliver, maybe he has a hint for you. It was slightly different from the fact, but your hint helped me enough. In case of multi selection, pCurCrsr indicated the blinking cursor. The SwPaM instance that corresponded to the last selected portion could be obtained by pCurCrsr->GetPrev(). I found this fact by trying SwCrsrShell::GetCrsrCnt() method. It returned 3 when I selected 2 discrete areas in Writer. I guessed it means 2 discrete selected parts and 1 independent blinking cursor. I hope this information will help those who want to hack Writer. BTW, when the focus is in a note (Note2) located in the side of page view, my patch for reconversion doesn't work. I guess another widget like SwEditWin catches the commands from VCL layer. Now I'm just getting started to investigate this problem, but please let me know which class can handle commands emitted from VCL layer for notes (PostIt) if you have any idea. Regards, -- Takashi Nakamoto <[EMAIL PROTECTED]> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
