1 package net.sourceforge.phpdt.externaltools.group;
3 /**********************************************************************
4 Copyright (c) 2002 IBM Corp. and others. All rights reserved.
5 This file is made available under the terms of the Common Public License v1.0
6 which accompanies this distribution, and is available at
7 http://www.eclipse.org/legal/cpl-v10.html
10 **********************************************************************/
12 import org.eclipse.jface.dialogs.IMessageProvider;
13 import org.eclipse.swt.layout.GridData;
14 import org.eclipse.swt.widgets.Button;
17 * Represents the API for a group of visual components
18 * to access the dialog page that contains it.
20 * This interface is not intended to be extended
21 * nor implemented by clients.
24 public interface IGroupDialogPage extends IMessageProvider {
26 * Sets the <code>GridData</code> on the specified button to
27 * be one that is spaced for the current dialog page units.
29 * @param button the button to set the <code>GridData</code>
30 * @return the <code>GridData</code> set on the specified button
32 public GridData setButtonGridData(Button button);
35 * Sets the message for this page with an indication of what type
38 * The valid message types are one of <code>NONE</code>,
39 * <code>INFORMATION</code>, <code>WARNING</code>, or <code>ERROR</code>.
42 * @param newMessage the message, or <code>null</code> to clear the message
43 * @param newType the message type
45 public void setMessage(String newMessage, int newType);
48 * Updates the page's valid state using the group's
49 * current valid state. This will cause the dialog's
50 * buttons dependent on the page's valid state to
51 * update to reflect the new state.
53 public void updateValidState();
56 * Converts a height in characters to a height in pixels.
58 * @param chars the height in characters to be converted
59 * @return the corresponding height in pixels
61 public int convertHeightHint(int chars);