Skip to content
  • Jan Hambrecht's avatar
    Implemneted dragging of guide lines from the rulers. · f8a25284
    Jan Hambrecht authored
    When dragging outside of the ruler, the ruler emits
    a signal guideLineCreated which when connected to the
    KoCanvasControllers slot addGuideLine will temporary 
    activate the KoGuidesTool. This tool then positions the
    new guide line corresponding to the mouse movement.
    When the mouse gets released, the guide line is added
    to the guides data provided by the canvas.
    To add support for guide lines to an application one
    has to do the follwoing steps:
    1. when creating your rulers, connect the guideLineCreated 
    signal with the canvas controllers addGuideLine slot.
    2. In the canvas implementation, reimplement the guidesData
    function to provide access to the guides data of the
    applications KoDocument implementation.
    3. In the canvas implementation call KoGuidesData::paintGuides
    to paint the guides.
    4. Profit!!! :-)
    
    
    svn path=/trunk/koffice/; revision=825673
    f8a25284