/******************************************************************************* * Copyright (c) 2013 Stephane Begaudeau (Obeo). * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * Stephane Begaudeau (Obeo) - initial API and implementation *******************************************************************************/ package org.obeonetwork.angularjs.eclipse.tools.ide.ui.internal.editors.packagejson; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.widgets.Composite; import org.eclipse.ui.forms.AbstractFormPart; import org.eclipse.ui.forms.editor.FormPage; import org.eclipse.ui.forms.widgets.ExpandableComposite; import org.eclipse.ui.forms.widgets.FormToolkit; import org.eclipse.ui.forms.widgets.Section; import org.obeonetwork.angularjs.eclipse.tools.ide.ui.internal.editors.FormLayoutFactory; /** * @author <a href="mailto:stephane.begaudeau@obeo.fr">Stephane Begaudeau</a> */ public class BundleDependencies extends AbstractFormPart { public BundleDependencies(FormPage formPage, Composite parent) { FormToolkit toolkit = formPage.getManagedForm().getToolkit(); Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR | Section.DESCRIPTION); section.setText("Bundle Dependencies"); section.setLayout(FormLayoutFactory.createClearTableWrapLayout(false, 1)); GridData gridData = new GridData(GridData.FILL_BOTH); section.setLayoutData(gridData); section.setDescription("This section describes general information about this project"); Composite client = toolkit.createComposite(section); client.setLayout(FormLayoutFactory.createSectionClientTableWrapLayout(false, 3)); section.setClient(client); } }