public LimitedTextArea(int linesMax){
  this.linesMax=linesMax;
  textArea=new JTextArea(10,40);
  textArea.setLineWrap(true);
  workPanel=new JScrollPane(textArea);
  workDoc=(PlainDocument)textArea.getDocument();
}

public LimitedTextArea ( int linesMax ) { this . linesMax = linesMax ; textArea = new JTextArea ( 10 , 40 ) ; textArea . setLineWrap ( true ) ; workPanel = new JScrollPane ( textArea ) ; workDoc = ( PlainDocument ) textArea . getDocument ( ) ; }
construct a given limited text area that holds at max linemax lines .
