We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpOther Libraries › [controlP5] Add a Textarea to a seperate window
Page Index Toggle Pages: 1
[controlP5] Add a Textarea to a seperate window (Read 636 times)
[controlP5] Add a Textarea to a seperate window
May 25th, 2008, 12:40pm
 
hi

first of all, thanks for the previous thread, this approach helps for Textarea as well:

http://processing.org/discourse/yabb_beta/YaBB.cgi?board=LibraryProblems;action=display;num=1210321802

However, I do have the problem, that the scrollbars dont work.

Code:

import controlP5.*;

ControlP5 controlP5;
Textarea myTextarea;
ControlWindow controlWindow;

void setup() {
size(400,400);
frameRate(30);
controlP5 = new ControlP5(this);
controlWindow = controlP5.addControlWindow("controlP5window",100,100,400,300);

controlP5.addTab(controlWindow, "new");

myTextarea = controlP5.addTextarea(
"label1",
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"a textarea is of type group, not controller.\n"+
"use ALT + mouseDown to move the textarea.",
100,100,200,60);
myTextarea.setTab("new");
controlP5.addSlider("changeWidth",0,200,100,100,20,100,9).moveTo(controlWindow);
controlP5.addSlider("changeHeight",0,200,100,100,60,100,9).moveTo(controlWindow);
myTextarea.setColorForeground(0xffff0000);
}


void draw() {
background(0);
fill(255);
}

void changeWidth(int theValue) {
myTextarea.setWidth(theValue);
// ((Textarea)controlP5.group("label1")).setWidth(theValue);
}

void changeHeight(int theValue) {
myTextarea.setHeight(theValue);
}



any ideas?

cheers

martin
Re: [controlP5] Add a Textarea to a seperate windo
Reply #1 - May 25th, 2008, 1:52pm
 
hi,
thanks for posting this, i am currently fixing it to make these controlWindow issues work. will post the update soon.
best,
andi

Re: [controlP5] Add a Textarea to a seperate windo
Reply #2 - May 25th, 2008, 5:49pm
 
see this post for updates.
Page Index Toggle Pages: 1