Problem setting frame position
in
Programming Questions
•
1 year ago
Hi,
Currently i have a JDC browser on my application, and "frame.setLayout(new GridLayout(x,y));" is the code which sets the browser to appear in my application, the problem is it's always occupying half the size of the application no matter how i alter the number x and y.
Besides that whenever i set frame.setResizable(true); it won't display the browser and sometimes there will be this error "illegalArgumentException: Width(116) and Height(0) cannot be <=0
Below is part of the code:
void setup() {
size(950,650);
frame.setResizable(true)
frame.setLayout(new GridLayout(1,2));
browser=new aBrowser[1];
browser[0]=new aBrowser();
browser[0].initPanel(400,300);
browser[0].setURL("http://www.google.com/");
frame.add(browser[0].panel);
Hope you all could help me, thanks.
1