Java JTextArea getTextAreaScrollPaneContainer(JTextArea textArea, int nbLines)

Here you can find the source of getTextAreaScrollPaneContainer(JTextArea textArea, int nbLines)

Description

get Text Area Scroll Pane Container

License

Apache License

Declaration

public static JScrollPane getTextAreaScrollPaneContainer(JTextArea textArea, int nbLines) 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import javax.swing.*;

public class Main {
    public static JScrollPane getTextAreaScrollPaneContainer(JTextArea textArea, int nbLines) {
        JScrollPane ret = new JScrollPane();
        textArea.setRows(nbLines);// ww w  . ja va2 s .  c o  m
        textArea.setColumns(20);
        ret.setViewportView(textArea);
        return ret;
    }
}

Related

  1. createTabArea(JTextArea area, int width)
  2. display(JTextArea txtOutput, String text)
  3. estimatedRows(JTextArea text)
  4. fixTabKeys(JTextArea textArea)
  5. getAreaValue(JTextArea ta)
  6. getTextDimension(JTextArea textArea, Dimension maxDimension)
  7. initLogConsole(final JTextArea textArea)
  8. initTextAreaEdit(JTextArea j1)
  9. makeLabelStyle(JTextArea textArea)