@ -372,9 +372,9 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
m_pageMode ( LinedStaff : : LinearMode ) ,
m_leftGutter ( 20 ) ,
m_notePixmapFactory ( new NotePixmapFactory ( m_fontName , m_fontSize ) ) ,
m_h tq layout( new NotationHLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_h layout( new NotationHLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_properties , TQT_TQOBJECT ( this ) ) ) ,
m_v tq layout( new NotationVLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_v layout( new NotationVLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_properties , TQT_TQOBJECT ( this ) ) ) ,
m_chordNameRuler ( 0 ) ,
m_tempoRuler ( 0 ) ,
@ -409,7 +409,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
// Initialise the display-related defaults that will be needed
// by both the actions and the tq layout toolbar
// by both the actions and the layout toolbar
m_config - > setGroup ( NotationViewConfigGroup ) ;
@ -435,15 +435,15 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
NoteFontFactory : : getDefaultSize ( m_fontName ) ) ;
int defaultSpacing = m_config - > readNumEntry ( " spacing " , 100 ) ;
m_h tq layout- > setSpacing ( defaultSpacing ) ;
m_h layout- > setSpacing ( defaultSpacing ) ;
int defaultProportion = m_config - > readNumEntry ( " proportion " , 60 ) ;
m_h tq layout- > setProportion ( defaultProportion ) ;
m_h layout- > setProportion ( defaultProportion ) ;
delete m_notePixmapFactory ;
m_notePixmapFactory = new NotePixmapFactory ( m_fontName , m_fontSize ) ;
m_h tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_v tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_h layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_v layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
setupActions ( ) ;
// setupAddControlRulerMenu(); - too early for notation, moved to end of ctor.
@ -460,19 +460,19 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
updateViewCaption ( ) ;
m_chordNameRuler = new ChordNameRuler
( m_h tq layout, doc , segments , m_leftGutter , 20 , getCentralWidget ( ) ) ;
( m_h layout, doc , segments , m_leftGutter , 20 , getCentralWidget ( ) ) ;
addRuler ( m_chordNameRuler ) ;
if ( showProgressive )
m_chordNameRuler - > show ( ) ;
m_tempoRuler = new TempoRuler
( m_h tq layout, doc , this , m_leftGutter , 24 , false , getCentralWidget ( ) ) ;
( m_h layout, doc , this , m_leftGutter , 24 , false , getCentralWidget ( ) ) ;
addRuler ( m_tempoRuler ) ;
m_tempoRuler - > hide ( ) ;
static_cast < TempoRuler * > ( m_tempoRuler ) - > connectSignals ( ) ;
m_rawNoteRuler = new RawNoteRuler
( m_h tq layout, segments [ 0 ] , m_leftGutter , 20 , getCentralWidget ( ) ) ;
( m_h layout, segments [ 0 ] , m_leftGutter , 20 , getCentralWidget ( ) ) ;
addRuler ( m_rawNoteRuler ) ;
m_rawNoteRuler - > show ( ) ;
@ -484,7 +484,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
readOptions ( ) ;
setBottomStandardRuler ( new StandardRuler ( getDocument ( ) , m_h tq layout, m_leftGutter , 25 ,
setBottomStandardRuler ( new StandardRuler ( getDocument ( ) , m_h layout, m_leftGutter , 25 ,
true , getBottomWidget ( ) ) ) ;
for ( unsigned int i = 0 ; i < segments . size ( ) ; + + i )
@ -506,7 +506,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
m_canvasView - > setLeftFixedWidget ( m_headersGroupView ) ;
// Add a close button just above the track headers.
// The grid tq layout is only here to maintain the button in a
// The grid layout is only here to maintain the button in a
// right place
m_headersTopFrame = new TQFrame ( getCentralWidget ( ) ) ;
TQGridLayout * headersTopGrid
@ -522,7 +522,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
TQToolTip : : add ( hideHeadersButton , i18n ( " Close track headers " ) ) ;
headersTopGrid - > setMargin ( 4 ) ;
setTopStandardRuler ( new StandardRuler ( getDocument ( ) ,
m_h tq layout, m_leftGutter , 25 ,
m_h layout, m_leftGutter , 25 ,
false , getCentralWidget ( ) ) , m_headersTopFrame ) ;
m_topStandardRuler - > getLoopRuler ( ) - > setBackgroundColor
@ -544,7 +544,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
//
// tq layout
// layout
//
ProgressDialog * progressDlg = 0 ;
@ -594,7 +594,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
} catch ( ProgressReporter : : Cancelled c )
{
// when cancelled, m_ok is false -- checked by calling method
NOTATION_DEBUG < < " NotationView ctor : tq layout Cancelled" < < endl ;
NOTATION_DEBUG < < " NotationView ctor : layout Cancelled" < < endl ;
}
NOTATION_DEBUG < < " NotationView ctor : m_ok = " < < m_ok < < endl ;
@ -817,9 +817,9 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
m_pageMode ( LinedStaff : : LinearMode ) ,
m_leftGutter ( 0 ) ,
m_notePixmapFactory ( new NotePixmapFactory ( m_fontName , m_fontSize ) ) ,
m_h tq layout( new NotationHLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_h layout( new NotationHLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_properties , TQT_TQOBJECT ( this ) ) ) ,
m_v tq layout( new NotationVLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_v layout( new NotationVLayout ( & doc - > getComposition ( ) , m_notePixmapFactory ,
m_properties , TQT_TQOBJECT ( this ) ) ) ,
m_chordNameRuler ( 0 ) ,
m_tempoRuler ( 0 ) ,
@ -850,7 +850,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
// Initialise the display-related defaults that will be needed
// by both the actions and the tq layout toolbar
// by both the actions and the layout toolbar
m_config - > setGroup ( NotationViewConfigGroup ) ;
@ -871,20 +871,20 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
if ( referenceView )
{
m_h tq layout- > setSpacing ( referenceView - > m_h tq layout- > getSpacing ( ) ) ;
m_h tq layout- > setProportion ( referenceView - > m_h tq layout- > getProportion ( ) ) ;
m_h layout- > setSpacing ( referenceView - > m_h layout- > getSpacing ( ) ) ;
m_h layout- > setProportion ( referenceView - > m_h layout- > getProportion ( ) ) ;
} else
{
int defaultSpacing = m_config - > readNumEntry ( " spacing " , 100 ) ;
m_h tq layout- > setSpacing ( defaultSpacing ) ;
m_h layout- > setSpacing ( defaultSpacing ) ;
int defaultProportion = m_config - > readNumEntry ( " proportion " , 60 ) ;
m_h tq layout- > setProportion ( defaultProportion ) ;
m_h layout- > setProportion ( defaultProportion ) ;
}
delete m_notePixmapFactory ;
m_notePixmapFactory = new NotePixmapFactory ( m_fontName , m_fontSize ) ;
m_h tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_v tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_h layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
m_v layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
setBackgroundMode ( PaletteBase ) ;
m_config - > setGroup ( NotationViewConfigGroup ) ;
@ -939,7 +939,7 @@ NotationView::NotationView(RosegardenGUIDoc *doc,
} catch ( ProgressReporter : : Cancelled c )
{
// when cancelled, m_ok is false -- checked by calling method
NOTATION_DEBUG < < " NotationView ctor : tq layout Cancelled" < < endl ;
NOTATION_DEBUG < < " NotationView ctor : layout Cancelled" < < endl ;
}
NOTATION_DEBUG < < " NotationView ctor : m_ok = " < < m_ok < < endl ;
@ -1223,7 +1223,7 @@ void NotationView::positionStaffs()
}
}
m_h tq layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
m_h layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
int topGutter = 0 ;
@ -1549,7 +1549,7 @@ void NotationView::setupActions()
KActionMenu * spacingActionMenu =
new KActionMenu ( i18n ( " S&pacing " ) , TQT_TQOBJECT ( this ) , " stretch_actionmenu " ) ;
int defaultSpacing = m_h tq layout- > getSpacing ( ) ;
int defaultSpacing = m_h layout- > getSpacing ( ) ;
std : : vector < int > spacings = NotationHLayout : : getAvailableSpacings ( ) ;
for ( std : : vector < int > : : iterator i = spacings . begin ( ) ;
@ -1571,7 +1571,7 @@ void NotationView::setupActions()
KActionMenu * proportionActionMenu =
new KActionMenu ( i18n ( " Du&ration Factor " ) , TQT_TQOBJECT ( this ) , " proportion_actionmenu " ) ;
int defaultProportion = m_h tq layout- > getProportion ( ) ;
int defaultProportion = m_h layout- > getProportion ( ) ;
std : : vector < int > proportions = NotationHLayout : : getAvailableProportions ( ) ;
for ( std : : vector < int > : : iterator i = proportions . begin ( ) ;
@ -1820,7 +1820,7 @@ void NotationView::setupActions()
TQString pixmapDir = KGlobal : : dirs ( ) - > findResource ( " appdata " , " pixmaps/ " ) ;
TQCanvasPixmap pixmap ( pixmapDir + " /toolbar/linear- tq layout.xpm" ) ;
TQCanvasPixmap pixmap ( pixmapDir + " /toolbar/linear- layout.xpm" ) ;
icon = TQIconSet ( pixmap ) ;
KRadioAction * linearModeAction = new KRadioAction
( i18n ( " &Linear Layout " ) , icon , 0 , TQT_TQOBJECT ( this ) , TQT_SLOT ( slotLinearMode ( ) ) ,
@ -2611,7 +2611,7 @@ void NotationView::initLayoutToolbar()
if ( ! layoutToolbar ) {
std : : cerr
< < " NotationView::initLayoutToolbar() : tq layout toolbar not found"
< < " NotationView::initLayoutToolbar() : layout toolbar not found"
< < std : : endl ;
return ;
}
@ -2679,7 +2679,7 @@ void NotationView::initLayoutToolbar()
//
// spacing combo
//
int defaultSpacing = m_h tq layout- > getSpacing ( ) ;
int defaultSpacing = m_h layout- > getSpacing ( ) ;
std : : vector < int > spacings = NotationHLayout : : getAvailableSpacings ( ) ;
m_spacingCombo = new KComboBox ( layoutToolbar , " spacing combo " ) ;
@ -2786,17 +2786,17 @@ NotationView::setPageMode(LinedStaff::PageMode pageMode)
int topMargin = 0 , leftMargin = 0 ;
getPageMargins ( leftMargin , topMargin ) ;
m_h tq layout- > setPageMode ( pageMode ! = LinedStaff : : LinearMode ) ;
m_h tq layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
m_h layout- > setPageMode ( pageMode ! = LinedStaff : : LinearMode ) ;
m_h layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
NOTATION_DEBUG < < " NotationView::setPageMode: set tq layout's page width to "
NOTATION_DEBUG < < " NotationView::setPageMode: set layout's page width to "
< < ( pageWidth - leftMargin * 2 ) < < endl ;
positionStaffs ( ) ;
bool layoutApplied = applyLayout ( ) ;
if ( ! layoutApplied )
KMessageBox : : sorry ( 0 , " Couldn't apply tq layout" ) ;
KMessageBox : : sorry ( 0 , " Couldn't apply layout" ) ;
else {
for ( unsigned int i = 0 ; i < m_staffs . size ( ) ; + + i ) {
m_staffs [ i ] - > markChanged ( ) ;
@ -2894,7 +2894,7 @@ void
NotationView : : scrollToTime ( timeT t )
{
double notationViewLayoutCoord = m_h tq layout- > getXForTime ( t ) ;
double notationViewLayoutCoord = m_h layout- > getXForTime ( t ) ;
// Doesn't appear to matter which staff we use
//!!! actually it probably does matter, if they don't have the same extents
@ -2912,7 +2912,7 @@ NotationView::scrollToTime(timeT t)
RulerScale *
NotationView : : getHLayout ( )
{
return m_h tq layout;
return m_h layout;
}
void
@ -2948,8 +2948,8 @@ NotationView::paintEvent(TQPaintEvent *e)
getPageMargins ( leftMargin , topMargin ) ;
if ( m_pageMode = = LinedStaff : : ContinuousPageMode ) {
// re tq layout if the window width changes significantly in continuous page mode
int diff = int ( getPageWidth ( ) - leftMargin * 2 - m_h tq layout- > getPageWidth ( ) ) ;
// re layout if the window width changes significantly in continuous page mode
int diff = int ( getPageWidth ( ) - leftMargin * 2 - m_h layout- > getPageWidth ( ) ) ;
if ( diff < - 10 | | diff > 10 ) {
setPageMode ( m_pageMode ) ;
refreshSegment ( 0 , 0 , 0 ) ;
@ -2998,7 +2998,7 @@ bool NotationView::applyLayout(int staffNo, timeT startTime, timeT endTime)
slotSetOperationNameAndStatus ( i18n ( " Laying out score... " ) ) ;
ProgressDialog : : processEvents ( ) ;
m_h tq layout- > setStaffCount ( m_staffs . size ( ) ) ;
m_h layout- > setStaffCount ( m_staffs . size ( ) ) ;
Profiler profiler ( " NotationView::applyLayout " ) ;
unsigned int i ;
@ -3011,17 +3011,17 @@ bool NotationView::applyLayout(int staffNo, timeT startTime, timeT endTime)
slotSetOperationNameAndStatus ( i18n ( " Laying out staff %1... " ) . arg ( i + 1 ) ) ;
ProgressDialog : : processEvents ( ) ;
m_h tq layout- > resetStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_v tq layout- > resetStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_h tq layout- > scanStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_v tq layout- > scanStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_h layout- > resetStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_v layout- > resetStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_h layout- > scanStaff ( * m_staffs [ i ] , startTime , endTime ) ;
m_v layout- > scanStaff ( * m_staffs [ i ] , startTime , endTime ) ;
}
slotSetOperationNameAndStatus ( i18n ( " Reconciling staffs... " ) ) ;
ProgressDialog : : processEvents ( ) ;
m_h tq layout- > finishLayout ( startTime , endTime ) ;
m_v tq layout- > finishLayout ( startTime , endTime ) ;
m_h layout- > finishLayout ( startTime , endTime ) ;
m_v layout- > finishLayout ( startTime , endTime ) ;
// find the last finishing staff for future use
@ -3349,10 +3349,10 @@ void NotationView::setNotePixmapFactory(NotePixmapFactory* f)
{
delete m_notePixmapFactory ;
m_notePixmapFactory = f ;
if ( m_h tq layout)
m_h tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
if ( m_v tq layout)
m_v tq layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
if ( m_h layout)
m_h layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
if ( m_v layout)
m_v layout- > setNotePixmapFactory ( m_notePixmapFactory ) ;
}
Segment *
@ -3469,7 +3469,7 @@ NotationView::getStaffForCanvasCoords(int x, int y) const
LinedStaff : : LinedStaffCoords coords =
s - > getLayoutCoordsForCanvasCoords ( x , y ) ;
timeT t = m_h tq layout- > getTimeForX ( coords . first ) ;
timeT t = m_h layout- > getTimeForX ( coords . first ) ;
// In order to find the correct starting and ending bar of the segment,
// make infinitesimal shifts (+1 and -1) towards its center.
timeT t0 = getDocument ( ) - > getComposition ( ) . getBarStartForTime ( m_staffs [ m_currentStaff ] - > getSegment ( ) . getStartTime ( ) + 1 ) ;
@ -3488,7 +3488,7 @@ NotationView::getStaffForCanvasCoords(int x, int y) const
LinedStaff : : LinedStaffCoords coords =
s - > getLayoutCoordsForCanvasCoords ( x , y ) ;
timeT t = m_h tq layout- > getTimeForX ( coords . first ) ;
timeT t = m_h layout- > getTimeForX ( coords . first ) ;
// In order to find the correct starting and ending bar of the segment,
// make infinitesimal shifts (+1 and -1) towards its center.
timeT t0 = getDocument ( ) - > getComposition ( ) . getBarStartForTime ( m_staffs [ i ] - > getSegment ( ) . getStartTime ( ) + 1 ) ;
@ -3589,8 +3589,8 @@ void NotationView::print(bool previewOnly)
LinedStaff : : LinedStaffCoords cc1 = staff - > getLayoutCoordsForCanvasCoords
( pageRect . x ( ) + pageRect . width ( ) , pageRect . y ( ) + pageRect . height ( ) ) ;
timeT t0 = m_h tq layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h tq layout- > getTimeForX ( cc1 . first ) ;
timeT t0 = m_h layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h layout- > getTimeForX ( cc1 . first ) ;
m_staffs [ i ] - > setPrintPainter ( & printpainter ) ;
m_staffs [ i ] - > checkRendered ( t0 , t1 ) ;
@ -3629,8 +3629,8 @@ void NotationView::print(bool previewOnly)
LinedStaff : : LinedStaffCoords cc1 = staff - > getLayoutCoordsForCanvasCoords
( pageRect . x ( ) + pageRect . width ( ) , pageRect . y ( ) + pageRect . height ( ) ) ;
timeT t0 = m_h tq layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h tq layout- > getTimeForX ( cc1 . first ) ;
timeT t0 = m_h layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h layout- > getTimeForX ( cc1 . first ) ;
m_staffs [ i ] - > renderPrintable ( t0 , t1 ) ;
}
@ -3886,7 +3886,7 @@ void NotationView::readjustCanvasSize()
LinedStaff & staff = * m_staffs [ i ] ;
staff . sizeStaff ( * m_h tq layout) ;
staff . sizeStaff ( * m_h layout) ;
UPDATE_PROGRESS ( 1 ) ;
if ( staff . getTotalWidth ( ) + staff . getX ( ) > maxWidth ) {
@ -4110,10 +4110,10 @@ void NotationView::setupProgress(KProgress* bar)
if ( bar ) {
NOTATION_DEBUG < < " NotationView::setupProgress(bar) \n " ;
connect ( m_h tq layout, TQT_SIGNAL ( setProgress ( int ) ) ,
connect ( m_h layout, TQT_SIGNAL ( setProgress ( int ) ) ,
bar , TQT_SLOT ( setValue ( int ) ) ) ;
connect ( m_h tq layout, TQT_SIGNAL ( incrementProgress ( int ) ) ,
connect ( m_h layout, TQT_SIGNAL ( incrementProgress ( int ) ) ,
bar , TQT_SLOT ( advance ( int ) ) ) ;
connect ( this , TQT_SIGNAL ( setProgress ( int ) ) ,
@ -4142,7 +4142,7 @@ void NotationView::setupProgress(ProgressDialog* dialog)
setupProgress ( dialog - > progressBar ( ) ) ;
connect ( dialog , TQT_SIGNAL ( cancelClicked ( ) ) ,
m_h tq layout, TQT_SLOT ( slotCancel ( ) ) ) ;
m_h layout, TQT_SLOT ( slotCancel ( ) ) ) ;
for ( unsigned int i = 0 ; i < m_staffs . size ( ) ; + + i ) {
connect ( m_staffs [ i ] , TQT_SIGNAL ( setOperationName ( TQString ) ) ,
@ -4170,7 +4170,7 @@ void NotationView::disconnectProgress()
{
NOTATION_DEBUG < < " NotationView::disconnectProgress() " < < endl ;
m_h tq layout- > disconnect ( ) ;
m_h layout- > disconnect ( ) ;
disconnect ( TQT_SIGNAL ( setProgress ( int ) ) ) ;
disconnect ( TQT_SIGNAL ( incrementProgress ( int ) ) ) ;
disconnect ( TQT_SIGNAL ( setOperationName ( TQString ) ) ) ;
@ -4324,10 +4324,10 @@ NotationView::slotChangeSpacingFromAction()
void
NotationView : : slotChangeSpacing ( int spacing )
{
if ( m_h tq layout- > getSpacing ( ) = = spacing )
if ( m_h layout- > getSpacing ( ) = = spacing )
return ;
m_h tq layout- > setSpacing ( spacing ) ;
m_h layout- > setSpacing ( spacing ) ;
// m_spacingSlider->setSize(spacing);
@ -4357,7 +4357,7 @@ NotationView::slotChangeSpacing(int spacing)
void
NotationView : : slotChangeProportionFromIndex ( int n )
{
std : : vector < int > proportions = m_h tq layout- > getAvailableProportions ( ) ;
std : : vector < int > proportions = m_h layout- > getAvailableProportions ( ) ;
if ( n > = ( int ) proportions . size ( ) )
n = proportions . size ( ) - 1 ;
slotChangeProportion ( proportions [ n ] ) ;
@ -4382,10 +4382,10 @@ NotationView::slotChangeProportionFromAction()
void
NotationView : : slotChangeProportion ( int proportion )
{
if ( m_h tq layout- > getProportion ( ) = = proportion )
if ( m_h layout- > getProportion ( ) = = proportion )
return ;
m_h tq layout- > setProportion ( proportion ) ;
m_h layout- > setProportion ( proportion ) ;
// m_proportionSlider->setSize(proportion);
@ -4581,7 +4581,7 @@ NotationView::slotChangeFont(std::string newName, int newSize)
int topMargin = 0 , leftMargin = 0 ;
getPageMargins ( leftMargin , topMargin ) ;
m_h tq layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
m_h layout- > setPageWidth ( pageWidth - leftMargin * 2 ) ;
}
for ( unsigned int i = 0 ; i < m_staffs . size ( ) ; + + i ) {
@ -4594,7 +4594,7 @@ NotationView::slotChangeFont(std::string newName, int newSize)
bool layoutApplied = applyLayout ( ) ;
if ( ! layoutApplied )
KMessageBox : : sorry ( 0 , " Couldn't apply tq layout" ) ;
KMessageBox : : sorry ( 0 , " Couldn't apply layout" ) ;
else {
for ( unsigned int i = 0 ; i < m_staffs . size ( ) ; + + i ) {
m_staffs [ i ] - > markChanged ( ) ;
@ -6438,22 +6438,22 @@ NotationView::slotSetPointerPosition(timeT time, bool scroll)
for ( unsigned int i = 0 ; i < m_staffs . size ( ) ; + + i ) {
double layoutX = m_h tq layout- > getXForTimeByEvent ( time ) ;
double layoutX = m_h layout- > getXForTimeByEvent ( time ) ;
Segment & seg = m_staffs [ i ] - > getSegment ( ) ;
bool good = true ;
if ( barNo > = m_h tq layout- > getLastVisibleBarOnStaff ( * m_staffs [ i ] ) ) {
if ( barNo > = m_h layout- > getLastVisibleBarOnStaff ( * m_staffs [ i ] ) ) {
if ( seg . isRepeating ( ) & & time < seg . getRepeatEndTime ( ) ) {
timeT mappedTime =
seg . getStartTime ( ) +
( ( time - seg . getStartTime ( ) ) %
( seg . getEndMarkerTime ( ) - seg . getStartTime ( ) ) ) ;
layoutX = m_h tq layout- > getXForTimeByEvent ( mappedTime ) ;
layoutX = m_h layout- > getXForTimeByEvent ( mappedTime ) ;
} else {
good = false ;
}
} else if ( barNo < m_h tq layout- > getFirstVisibleBarOnStaff ( * m_staffs [ i ] ) ) {
} else if ( barNo < m_h layout- > getFirstVisibleBarOnStaff ( * m_staffs [ i ] ) ) {
good = false ;
}
@ -6750,7 +6750,7 @@ NotationView::doDeferredCursorMove()
t = = segment . getEndTime ( ) | |
t = = segment . getBarStartForTime ( t ) ) {
staff - > setInsertCursorPosition ( * m_h tq layout, t ) ;
staff - > setInsertCursorPosition ( * m_h layout, t ) ;
if ( type = = CursorMoveAndMakeVisible ) {
double cx ;
@ -6976,21 +6976,21 @@ void NotationView::slotMultiPageMode()
void NotationView : : slotToggleChordsRuler ( )
{
if ( m_h tq layout- > isPageMode ( ) )
if ( m_h layout- > isPageMode ( ) )
return ;
toggleWidget ( m_chordNameRuler , " show_chords_ruler " ) ;
}
void NotationView : : slotToggleRawNoteRuler ( )
{
if ( m_h tq layout- > isPageMode ( ) )
if ( m_h layout- > isPageMode ( ) )
return ;
toggleWidget ( m_rawNoteRuler , " show_raw_note_ruler " ) ;
}
void NotationView : : slotToggleTempoRuler ( )
{
if ( m_h tq layout- > isPageMode ( ) )
if ( m_h layout- > isPageMode ( ) )
return ;
toggleWidget ( m_tempoRuler , " show_tempo_ruler " ) ;
}
@ -7116,7 +7116,7 @@ void NotationView::slotNonNotationItemPressed(TQMouseEvent *e, TQCanvasItem *it)
} else if ( dynamic_cast < TQCanvasTimeSigSprite * > ( it ) ) {
double layoutX = ( dynamic_cast < TQCanvasTimeSigSprite * > ( it ) ) - > getLayoutX ( ) ;
emit editTimeSignature ( m_h tq layout- > getTimeForX ( layoutX ) ) ;
emit editTimeSignature ( m_h layout- > getTimeForX ( layoutX ) ) ;
}
}
@ -7396,8 +7396,8 @@ NotationView::slotCheckRendered(double cx0, double cx1)
LinedStaff : : LinedStaffCoords cc1 = staff - > getLayoutCoordsForCanvasCoords
( cx1 , staff - > getTotalHeight ( ) + staff - > getY ( ) ) ;
timeT t0 = m_h tq layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h tq layout- > getTimeForX ( cc1 . first ) ;
timeT t0 = m_h layout- > getTimeForX ( cc0 . first ) ;
timeT t1 = m_h layout- > getTimeForX ( cc1 . first ) ;
if ( dynamic_cast < NotationStaff * > ( staff ) - > checkRendered ( t0 , t1 ) ) {
something = true ; //!!!