MuseScore  3.4
Music composition and notation
systemdivider.h
Go to the documentation of this file.
1 //=============================================================================
2 // MuseScore
3 // Music Composition & Notation
4 //
5 // Copyright (C) 2002-2011 Werner Schweer
6 //
7 // This program is free software; you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License version 2
9 // as published by the Free Software Foundation and appearing in
10 // the file LICENCE.GPL
11 //=============================================================================
12 
13 #ifndef __SYSTEMDIVIDER_H__
14 #define __SYSTEMDIVIDER_H__
15 
16 #include "symbol.h"
17 #include "sym.h"
18 
19 namespace Ms {
20 
21 //---------------------------------------------------------
22 // SystemDivider
23 //---------------------------------------------------------
24 
25 class SystemDivider final : public Symbol {
26  public:
27  enum Type { LEFT, RIGHT };
28 
29  private:
31 
32  public:
33  SystemDivider(Score* s = 0);
35 
36  virtual SystemDivider* clone() const override { return new SystemDivider(*this); }
37  virtual ElementType type() const override { return ElementType::SYSTEM_DIVIDER; }
38 
39  Type dividerType() const { return _dividerType; }
40  void setDividerType(Type v);
41 
42  virtual QRectF drag(EditData&) override;
43  virtual void write(XmlWriter&) const override;
44  virtual void read(XmlReader&) override;
45  virtual void layout() override;
46 
47  virtual Segment* segment() const override { return 0; }
48  System* system() const { return (System*)parent(); }
49  };
50 
51 } // namespace Ms
52 
53 #endif
54 
virtual Segment * segment() const override
Definition: systemdivider.h:47
Definition: xml.h:67
Type _dividerType
Definition: systemdivider.h:30
Definition: systemdivider.h:27
virtual QRectF drag(EditData &) override
Return update Rect relative to canvas.
Definition: systemdivider.cpp:76
virtual void read(XmlReader &) override
Definition: systemdivider.cpp:100
virtual ElementType type() const override
Definition: systemdivider.h:37
Type dividerType() const
Definition: systemdivider.h:39
SystemDivider(Score *s=0)
Definition: systemdivider.cpp:25
virtual void write(XmlWriter &) const override
Definition: systemdivider.cpp:86
Element * parent() const
Definition: element.h:192
Definition: score.h:391
virtual SystemDivider * clone() const override
Definition: systemdivider.h:36
Definition: systemdivider.h:27
Definition: segment.h:50
System * system() const
Definition: systemdivider.h:48
Definition: aeolus.cpp:26
Definition: xml.h:218
virtual void layout() override
Definition: systemdivider.cpp:46
Symbol constructed from builtin symbol.
Definition: symbol.h:31
Definition: element.h:111
Definition: systemdivider.h:25
void setDividerType(Type v)
Definition: systemdivider.cpp:63
One row of measures for all instruments; a complete piece of the timeline.
Definition: system.h:79
ElementType
Definition: types.h:34
Type
Definition: systemdivider.h:27