Shift-Spacebar increments CPPostion by two

  • If I type ABC (then press the space bar) the CPPostion will be at 3. If I type the same thing but press the Shift Key and the Spacebar at the same time, the CPPostion will be at 4.

    This is causing us an issue in performing certain functions that require us to know the CPPosition.

    • Offizieller Beitrag

    I tested this with

    procedure TWPTBXForm.WPRichText1Change(Sender: TObject);
    begin
    Caption := IntToStr( WPRichText1.CPPosition );
    end;

    I have the same result wether I press Shift or not. It is possible
    that you have a shortcut or an event in place with changes things?

    CPPosition is accurate - it is calculated from ActiveParagraph and ActivePosInPar using this code: