/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package cz.karry.dop.nbmodule.dbg;

import java.awt.Image;
import org.netbeans.editor.AnnotationDesc;
import org.netbeans.editor.AnnotationTypes;

/**
 *
 * @author karry
 */
class DbgAnnotation extends AnnotationDesc{
    private int offset;
    private int srcLine;
    //private static final Image image = org.openide.util.Utilities.loadImage("org/netbeans/modules/debugger/resources/editor/Breakpoint.png");
    private static final Image image = org.openide.util.Utilities.loadImage("cz/karry/dop/nbmodule/arrow.gif");
    

    public DbgAnnotation(int srcLine, int offset, int length) {
        super(offset, length);
        this.srcLine = srcLine;
        this.offset = offset;
    }

    @Override
    public String getAnnotationType() {
        // FIXME
        return "McuDbgCurrentInstruction";
    }

    @Override
    public String getShortDescription() {
        return "Actual microinstruction";
    }

    @Override
    public int getOffset() {
        return offset;
    }

    @Override
    public int getLine() {
        return srcLine;
    }
    
    @Override
    public Image getGlyph() {
        if (image == null){
            return super.getGlyph();
        }else{
            return image;
        }
    }

}
