1. /*
  2. * @(#)WindowsEditorPaneUI.java 1.12 00/02/02
  3. *
  4. * Copyright 1997-2000 Sun Microsystems, Inc. All Rights Reserved.
  5. *
  6. * This software is the proprietary information of Sun Microsystems, Inc.
  7. * Use is subject to license terms.
  8. *
  9. */
  10. package com.sun.java.swing.plaf.windows;
  11. import javax.swing.plaf.*;
  12. import javax.swing.plaf.basic.*;
  13. import javax.swing.*;
  14. import javax.swing.text.Caret;
  15. /**
  16. * Windows rendition of the component.
  17. * <p>
  18. * <strong>Warning:</strong>
  19. * Serialized objects of this class will not be compatible with
  20. * future Swing releases. The current serialization support is appropriate
  21. * for short term storage or RMI between applications running the same
  22. * version of Swing. A future release of Swing will provide support for
  23. * long term persistence.
  24. */
  25. public class WindowsEditorPaneUI extends BasicEditorPaneUI
  26. {
  27. /**
  28. * Creates a UI for a JEditorPane.
  29. *
  30. * @param c the configurable text component
  31. * @return the UI
  32. */
  33. public static ComponentUI createUI(JComponent c) {
  34. return new WindowsEditorPaneUI();
  35. }
  36. /**
  37. * Creates the object to use for a caret. By default an
  38. * instance of WindowsCaret is created. This method
  39. * can be redefined to provide something else that implements
  40. * the InputPosition interface or a subclass of DefaultCaret.
  41. *
  42. * @return the caret object
  43. */
  44. protected Caret createCaret() {
  45. return new WindowsTextUI.WindowsCaret();
  46. }
  47. }