2015-01-21 21:58:35 +01:00
|
|
|
/*******************************************************************************
|
2015-10-22 00:25:12 +02:00
|
|
|
* Copyright (c) 2015 MINRES Technologies GmbH and others.
|
2015-01-21 21:58:35 +01:00
|
|
|
* All rights reserved. This program and the accompanying materials
|
|
|
|
* are made available under the terms of the Eclipse Public License v1.0
|
|
|
|
* which accompanies this distribution, and is available at
|
|
|
|
* http://www.eclipse.org/legal/epl-v10.html
|
|
|
|
*
|
|
|
|
* Contributors:
|
|
|
|
* MINRES Technologies GmbH - initial API and implementation
|
|
|
|
*******************************************************************************/
|
2015-01-25 14:23:34 +01:00
|
|
|
package com.minres.scviewer.database.swt.internal;
|
2015-01-20 18:50:15 +01:00
|
|
|
|
2015-11-06 19:29:36 +01:00
|
|
|
import com.minres.scviewer.database.ui.TrackEntry;
|
|
|
|
|
|
|
|
public abstract class TrackPainter implements IWaveformPainter {
|
|
|
|
|
|
|
|
protected boolean even;
|
|
|
|
|
|
|
|
protected TrackEntry trackEntry;
|
|
|
|
|
|
|
|
public TrackPainter(TrackEntry trackEntry, boolean even) {
|
|
|
|
this.trackEntry = trackEntry;
|
|
|
|
this.even=even;
|
|
|
|
}
|
|
|
|
|
|
|
|
public int getHeight() {
|
|
|
|
return trackEntry.height;
|
2015-01-20 18:50:15 +01:00
|
|
|
}
|
|
|
|
|
2015-11-06 19:29:36 +01:00
|
|
|
public int getVerticalOffset() {
|
|
|
|
return trackEntry.vOffset;
|
2015-01-20 18:50:15 +01:00
|
|
|
}
|
2015-11-06 19:29:36 +01:00
|
|
|
|
|
|
|
public boolean isEven() {
|
|
|
|
return even;
|
|
|
|
}
|
|
|
|
|
|
|
|
public TrackEntry getTrackEntry() {
|
|
|
|
return trackEntry;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|