public int open(){ isOpen = true; if (sashWeights == null){ int width = getSashForm().getClientArea().width; if (width - 100 > 0) width -= 100; else width = width/2; sashWeights = new int[]{width, getSashForm().getClientArea().width-width}; } getSashForm().setWeights(sashWeights); return super.open(); }
public int open() { isOpen = true; if (sashWeights == null) { int a, b, c; int height = getSashForm().getClientArea().height; if (height < 250) { a = b = c = height / 3; } else { a = 100; // Details section needs about 100 c = 100; // Text area gets 100 b = height - a - c; // Stack trace should take up majority of room } sashWeights = new int[] {a, b, c}; } getSashForm().setWeights(sashWeights); return super.open(); }
public void handleEvent(Event arg0) int overallWidth = sashForm.getClientArea().width; int[] widths = new int[sashForm.getSashWidth()];
System.out.println("Weights changed!"); oldWeight = weights[0]; leftWidth = (int) Math.round((double) form.getClientArea().width * (double) weights[0] / (double) (weights[0] + weights[1])); @Override public void handleEvent(Event arg0) { int width = form.getClientArea().width; int[] weights = form.getWeights();
int width = form.getClientArea().width;
int width = sash.getClientArea().width;
@Override protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) return;
@Override protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) return;
@Override protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) return;
protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) return;
@Override protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) return;
@Override protected void layout(Composite composite, boolean flushCache) { SashForm sashForm = (SashForm)composite; Rectangle area = sashForm.getClientArea(); if (area.width <= 1 || area.height <= 1) { return;
Rectangle area = getClientArea(); boolean correction = false; if (getOrientation() == SWT.HORIZONTAL) {
Rectangle area = getClientArea(); boolean correction = false; if (getOrientation() == SWT.HORIZONTAL) {
Rectangle area = getClientArea(); boolean correction = false; if (getOrientation() == SWT.HORIZONTAL) {
Rectangle area = getClientArea(); boolean correction = false; if (getOrientation() == SWT.HORIZONTAL) {
Rectangle area = getClientArea(); boolean correction = false; if (getOrientation() == SWT.HORIZONTAL) {
Rectangle b2 = c2.getBounds(); Rectangle sashBounds = sash.getBounds(); Rectangle area = getClientArea(); boolean correction = false; if( getOrientation() == SWT.HORIZONTAL ) {