Example usage for javax.swing.plaf TextUI getRootView

List of usage examples for javax.swing.plaf TextUI getRootView

Introduction

In this page you can find the example usage for javax.swing.plaf TextUI getRootView.

Prototype

public abstract View getRootView(JTextComponent t);

Source Link

Document

Fetches a View with the allocation of the associated text component (i.e.

Usage

From source file:TextComponentDisplay.java

public static void displayViews(JTextComponent comp, PrintStream out) {
    TextUI textUI = (TextUI) comp.getUI();
    View rootView = textUI.getRootView(comp);

    displayView(rootView, 0, out);/*from  ww  w.  j  a v a2 s .  c  o  m*/
}