Package com.google.gwt.user.client.ui

Examples of com.google.gwt.user.client.ui.VerticalPanel


    public void onModuleLoad() {
        final TextBox nameField = new TextBox();
        nameField.setText("GWT User");
        final Button button = new Button("Check");

        VerticalPanel vp = new VerticalPanel();
        vp.add(nameField);
        vp.add(button);
        RootPanel.get().add(vp);

        button.addClickHandler(new ClickHandler() {
            @Override
            public void onClick(ClickEvent event) {
View Full Code Here


    final Button closeButton = new Button("Close");
    // We can set the id of a widget by accessing its Element
    closeButton.getElement().setId("closeButton");
    final Label textToServerLabel = new Label();
    final HTML serverResponseLabel = new HTML();
    VerticalPanel dialogVPanel = new VerticalPanel();
    dialogVPanel.addStyleName("dialogVPanel");
    dialogVPanel.add(new HTML("<b>Sending name to the server:</b>"));
    dialogVPanel.add(textToServerLabel);
    dialogVPanel.add(new HTML("<br><b>Server replies:</b>"));
    dialogVPanel.add(serverResponseLabel);
    dialogVPanel.setHorizontalAlignment(VerticalPanel.ALIGN_RIGHT);
    dialogVPanel.add(closeButton);
    dialogBox.setWidget(dialogVPanel);

    // Add a handler to close the DialogBox
    closeButton.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
View Full Code Here

    final Button closeButton = new Button("Close");
    // We can set the id of a widget by accessing its Element
    closeButton.getElement().setId("closeButton");
    final Label textToServerLabel = new Label();
    final HTML serverResponseLabel = new HTML();
    VerticalPanel dialogVPanel = new VerticalPanel();
    dialogVPanel.addStyleName("dialogVPanel");
    dialogVPanel.add(new HTML("<b>Sending name to the server:</b>"));
    dialogVPanel.add(textToServerLabel);
    dialogVPanel.add(new HTML("<br><b>Server replies:</b>"));
    dialogVPanel.add(serverResponseLabel);
    dialogVPanel.setHorizontalAlignment(VerticalPanel.ALIGN_RIGHT);
    dialogVPanel.add(closeButton);
    dialogBox.setWidget(dialogVPanel);

    // Add a handler to close the DialogBox
    closeButton.addClickHandler(new ClickHandler() {
      @Override
View Full Code Here

  private static volatile double GOLDEN__RATIO = 1.618;

  public void onModuleLoad() {
    try {
     
      VerticalPanel v = new VerticalPanel();
      v.setSpacing(20);
      RootPanel.get().add(v);
     
      ChartPanel chartPanel = Chronoscope.createTimeseriesChartWithDatasetVarName(
          "interestRates01", "interestRates02");
      chartPanel.getElement().getStyle().setCursor(Cursor.POINTER);
      chartPanel.setViewReadyCallback(new ViewReadyCallback() {
        public void onViewReady(final View view) {
          Dataset<?> dataset = view.getChart().getPlot().getDatasets().get(0);
          final Marker m = new Marker(dataset.getDomainExtrema().midpoint(),
              "A", 0);
          m.addOverlayClickListener(new OverlayClickListener() {
            public void onOverlayClick(Overlay overlay, int x, int y) {
              m.openInfoWindow("Hello");
            }
          });

          XYPlot<?> plot = view.getChart().getPlot();
          plot.setOverviewVisible(true);
          plot.setDatasetRenderer(1, new LineXYRenderer());
          plot.addOverlay(m);
          ((DefaultXYPlot<?>)plot).redraw(true);
        }
      });
      v.add(chartPanel);

      final ChartPanel chartPanel2 = Chronoscope.createTimeseriesChartWithDatasetVarName(
          "interestRates01", "interestRates02");
      int chartWidth = 600;
      int chartHeight = (int) (chartWidth / GOLDEN__RATIO);
      chartPanel2.setDimensions(chartWidth, chartHeight);
      chartPanel2.getElement().getStyle().setBorderStyle(BorderStyle.SOLID);
      chartPanel2.getElement().getStyle().setPadding(5, Unit.PX);
      v.add(chartPanel2);

    } catch (Exception e) {
      e.printStackTrace();
    }
  }
View Full Code Here

   /**
    *
    */
  public FormularioProfesionalSalud() {
   
    VerticalPanel verticalPanel = new VerticalPanel();
    initWidget(verticalPanel);
    verticalPanel.setSize("330px", "143px");
   
    final Label lblProfesionalSalud_1 = new Label("Profesional Salud");
    lblProfesionalSalud_1.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);
    lblProfesionalSalud_1.setStyleName("lztitulo-seccion");
    verticalPanel.add(lblProfesionalSalud_1);
   
    FlexTable flexTable = new FlexTable();
    flexTable.setStyleName("tabla-general");
   
    verticalPanel.add(flexTable);
    flexTable.setBorderWidth(0);
    flexTable.setSize("500", "");
    /*
     *
     */
 
View Full Code Here

    /*
     * LAYOUT SCREEN
     * Generic Root Panel
     */
    RootPanel rootPanel = RootPanel.get();   
    VerticalPanel verticalPanel = new VerticalPanel();
    verticalPanel.setStyleName("tableEntryPoint");
    rootPanel.add(verticalPanel, 10, 10);
    verticalPanel.setSize("502px", "171px");
    Label lblAsignarBloque = new Label("ReAsignar Horario Medico");
    lblAsignarBloque.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);
    lblAsignarBloque.setStyleName("lztitulo-formulario");
    verticalPanel.add(lblAsignarBloque);
   
    Button btnIngresarRegistro = new Button("Ingresar Registro");
    /*
     * Example event button IngresarRegistro
     */
    btnIngresarRegistro.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        // Dialog Box
         final DialogBox dialogBox = crearVentanaIngreso(event);
             dialogBox.center();
             dialogBox.show();
      }
    });
    verticalPanel.add(btnIngresarRegistro);
    verticalPanel.setCellHorizontalAlignment(btnIngresarRegistro, HasHorizontalAlignment.ALIGN_RIGHT);
       
    verticalPanel.add(formularioProfesionalSalud);
    formularioProfesionalSalud.setWidth("452px");
       
    verticalPanel.add(bloqueHorario);
    bloqueHorario.setWidth("494px");
   
//    Botones botones = new Botones();
//    verticalPanel.add(botones);
//    botones.setWidth("502px");
View Full Code Here

        final DialogBox dialogBox = new DialogBox();
       /*
           * Se crear un layout vertical para agregar los componente
           * se puede usar otro componente layout
           */
          VerticalPanel dialogContents = new VerticalPanel();
          dialogContents.setStyleName("tabla-general");    
          dialogContents.setSpacing(4);
          dialogBox.setWidget(dialogContents);
          // Llamada a componente
          IngresarProfesional ingresarProfesional = new IngresarProfesional();
          dialogContents.add(new Label("Ingreso de Profesional"));
          dialogContents.add(ingresarProfesional);
          /*
           * Botones
           * Two button Example
           */
          Button closeButton = new Button("Guardar", new ClickHandler() {
              public void onClick(ClickEvent event) {
                Window.alert("Guardar");
                  dialogBox.hide();
              }
          });
         
          // Add a close button at the bottom of the dialog
          Button deleteButton = new Button("Cancelar", new ClickHandler() {
              public void onClick(ClickEvent event) {
                Window.alert("Cancelar");
                  dialogBox.hide();
              }
          });  
         
        Grid gridBotones = new Grid(1, 3);
        gridBotones.setSize("", "");
        gridBotones.setWidget(0, 1, closeButton);
        gridBotones.setWidget(0, 2, deleteButton);
        gridBotones.getCellFormatter().setWidth(0, 0, "200px");
        gridBotones.getCellFormatter().setHeight(0, 0, "15px");
        gridBotones.getCellFormatter().setWidth(0, 1, "80px");
        gridBotones.getCellFormatter().setWidth(0, 2, "80px");

      dialogContents.add(gridBotones);
      return dialogBox;
     
  }
View Full Code Here

   
    bodyHtml = new HTML();
//      bodyHtml.setWidth("700px");
   
    if ( useDecoratorPanel ) {
      CellPanel p = new VerticalPanel();
      DecoratorPanel decPanel = new DecoratorPanel();
      decPanel.setWidget(p);
      add(decPanel);
      if ( useScroller ) {
        scroller = new ScrollPanel(bodyHtml);
//        scroller.setSize("450px", "120px");
//        scroller.setWidth("450px");
        p.add(scroller);
      }
      else {
        p.add(decPanel);
      }
    }
    else if ( useScroller ) {
      scroller = new ScrollPanel(bodyHtml);
      add(scroller);
View Full Code Here

      return;
    }
   
    StringBuffer sb = new StringBuffer();
   
    VerticalPanel vp = new VerticalPanel();
    vp.setSpacing(4);
    sb.append(error);
   
    String msg = sb.toString();
   
    popup.getTextArea().setText(msg);
View Full Code Here

   
    String error = uploadOntologyResult.getError();
   
    StringBuffer sb = new StringBuffer();
   
    VerticalPanel vp = new VerticalPanel();
    vp.setSpacing(6);
   
    if ( error == null ) {

      String uri = uploadOntologyResult.getUri();

      vp.add(new HTML("<font color=\"green\">Congratulations!</font> "
          + "Your ontology is now registered."
      ));
     
     
      vp.add(new HTML("<br/>The URI of the ontology is: "
//          + "<a href=\"" +uri+ "\">"
          + uri
//          + "</a>"
      ));
     
     
      vp.add(new HTML("<br/>For diagnostics, this is the response from the back-end server:"));

      sb.append(uploadOntologyResult.getInfo());
     
      // and, disable all editing fields/buttons:
      // (user will have to start from the "load" step)
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.ui.VerticalPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.