/*
 * @(#)NumberedEditorKit.java
 *
 * Copyright (c) 2005 by the original authors of JHotDraw and all its
 * contributors. All rights reserved.
 *
 * You may not use, copy or modify this file, except in compliance with the
 * license agreement you entered into with the copyright holders. For details
 * see accompanying license terms.
 *
 * Original version (c) Stanislav Lapitsky
 * http://www.developer.com/java/other/article.php/3318421
 */

package org.jhotdraw.samples.teddy.text;

import javax.swing.text.*;
/**
 * NumberedEditorKit.
 * 

* Usage: *

 * JEditorPane edit = new JEditorPane();
 * edit.setEditorKit(new NumberedEditorKit());
 * 
* * @author Werner Randelshofer * @version $Id: NumberedEditorKit.java 723 2010-12-28 14:31:24Z rawcoder $ */ public class NumberedEditorKit extends StyledEditorKit { private NumberedViewFactory viewFactory; @Override public ViewFactory getViewFactory() { if (viewFactory == null) { viewFactory = new NumberedViewFactory(); } return viewFactory; } }

Ads help maintain this website.