⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 notationstaff.h

📁 LINUX下的混音软件
💻 H
📖 第 1 页 / 共 2 页
字号:
    /**     * Delete all repeated clefs and keys.     */    virtual void deleteRepeatedClefsAndKeys();    /**     * (Re)draw the staff name from the track's current name     */    virtual void drawStaffName();    /**     * Return true if the staff name as currently drawn is up-to-date     * with that in the composition     */    virtual bool isStaffNameUpToDate();    /**     * Return the clef and key in force at the given canvas     * coordinates     */    virtual void getClefAndKeyAtCanvasCoords(double x, int y,                                             Clef &clef,                                             ::Rosegarden::Key &key) const;    /**     * Return the note name (C4, Bb3, whatever) corresponding to the     * given canvas coordinates     */    virtual std::string getNoteNameAtCanvasCoords    (double x, int y,     Accidental accidental =     Accidentals::NoAccidental) const;    /**     * Find the NotationElement whose layout x-coord is closest to x,     * without regard to its y-coord.     *     * If notesAndRestsOnly is true, will return the closest note     * or rest but will never return any other kind of element.     *      * If the closest event is further than \a proximityThreshold     * horizontally away from x, in pixels, end() is returned.     * (If proximityThreshold is negative, there will be no limit     * to the distances that will be considered.)     *     * Also returns the clef and key in force at the given coordinate.     */    virtual ViewElementList::iterator getClosestElementToLayoutX    (double x, Event *&clef, Event *&key,     bool notesAndRestsOnly = false,     int proximityThreshold = 10);    /**     * Find the NotationElement "under" the given layout x-coord,     * without regard to its y-coord.     *     * Also returns the clef and key in force at the given coordinates.     */    virtual ViewElementList::iterator getElementUnderLayoutX    (double x, Event *&clef, Event *&key);    /**     * Draw a note on the staff to show an insert position prior to     * an insert.      */    virtual void showPreviewNote(double layoutX, int heightOnStaff,                                 const Note &note);    /**     * Remove any visible preview note.     */    virtual void clearPreviewNote();    /**     * Overridden from Staff<T>.     * We want to avoid wrapping things like controller events, if     * our showUnknowns preference is off     */    virtual bool wrapEvent(Event *);    /**     * Override from Staff<T>     * Let tools know if their current element has gone     */    virtual void eventRemoved(const Segment *, Event *);    /**     * Return the view-local PropertyName definitions for this staff's view     */    const NotationProperties &getProperties() const;    virtual double getBarInset(int barNo, bool isFirstBarInRow) const;protected:    virtual ViewElement* makeViewElement(Event*);    // definition of staff    virtual int getLineCount() const         { return 5; }    virtual int getLegerLineCount() const    { return m_legerLineCount; }    virtual int getBottomLineHeight() const  { return 0; }    virtual int getHeightPerLine() const     { return 2; }    virtual int showBarNumbersEvery() const  { return m_barNumbersEvery; }    virtual BarStyle getBarStyle(int barNo) const;    /**      * Assign a suitable sprite to the given element (the clef is     * needed in case it's a key event, in which case we need to judge     * the correct pitch for the key)     */    virtual void renderSingleElement(ViewElementList::iterator &,                                     const Clef &,                                     const ::Rosegarden::Key &,                                     bool selected);    bool isDirectlyPrintable(ViewElement *elt);    void setTuplingParameters(NotationElement *, NotePixmapParameters &);    /**     * Set a sprite representing the given note event to the given notation element     */    virtual void renderNote(ViewElementList::iterator &);    /**     * Return a NotationElementList::iterator pointing to the     * start of a bar prior to the given time that doesn't appear     * to have been affected by any changes around that time     */    NotationElementList::iterator findUnchangedBarStart(timeT);    /**     * Return a NotationElementList::iterator pointing to the     * end of a bar subsequent to the given time that doesn't appear     * to have been affected by any changes around that time     */    NotationElementList::iterator findUnchangedBarEnd(timeT);    /**     * Return true if the element has a canvas item that is already     * at the correct coordinates     */    virtual bool elementNotMoved(NotationElement *);    /**     * Return true if the element has a canvas item that is already     * at the correct y-coordinate     */    virtual bool elementNotMovedInY(NotationElement *);    /**     * Returns true if the item at the given iterator appears to have     * moved horizontally without the spacing around it changing.     *      * In practice, calculates the offset between the intended layout     * and current canvas coordinates of the item at the given     * iterator, and returns true if this offset is equal to those of     * all other following iterators at the same time as well as the     * first iterator found at a greater time.     */    virtual bool elementShiftedOnly(NotationElementList::iterator);    enum FitPolicy {        PretendItFittedAllAlong = 0,        MoveBackToFit,        SplitToFit    };    /**     * Prepare a painter to draw an object of logical width w at     * layout-x coord x, starting at offset dx into the object, by     * setting the painter's clipping so as to crop the object at the     * right edge of the row if it would otherwise overrun.  The     * return value is the amount of the object visible on this row     * (i.e. the increment in offset for the next call to this method)     * or zero if no crop was necessary.  The canvas coords at which     * the object should subsequently be drawn are returned in coords.     *     * This function calls painter.save(), and the caller must call     * painter.restore() after use.     */    virtual double setPainterClipping(QPainter *, double layoutX, int layoutY,                                      double dx, double w, LinedStaffCoords &coords,                                      FitPolicy policy);    /**     * Set a single pixmap to a notation element, or split it into     * bits if it overruns the end of a row and set the bits     * separately.     */    virtual void setPixmap(NotationElement *, QCanvasPixmap *, int z,                           FitPolicy policy);    bool isSelected(NotationElementList::iterator);    typedef std::set<QCanvasSimpleSprite *> SpriteSet;    SpriteSet m_timeSigs;    typedef std::set<QCanvasItem *> ItemSet;    ItemSet m_repeatedClefsAndKeys;    typedef std::pair<int, Clef> ClefChange;    FastVector<ClefChange> m_clefChanges;    typedef std::pair<int, ::Rosegarden::Key> KeyChange;    FastVector<KeyChange> m_keyChanges;    void truncateClefsAndKeysAt(int);    NotePixmapFactory *m_notePixmapFactory;    NotePixmapFactory *m_graceNotePixmapFactory;    QCanvasSimpleSprite *m_previewSprite;    QCanvasSimpleSprite *m_staffName;    std::string m_staffNameText;    NotationView *m_notationView;    int m_legerLineCount;    int m_barNumbersEvery;    bool m_colourQuantize;    bool m_showUnknowns;    bool m_showRanges;    bool m_showCollisions;    int m_keySigCancelMode;    QPainter *m_printPainter;    enum BarStatus { UnRendered = 0, Rendered, Positioned };    typedef std::map<int, BarStatus> BarStatusMap;    BarStatusMap m_status;    std::pair<int, int> m_lastRenderCheck;    bool m_ready;};}#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -