学用Java

奇新Java控件---Java控件提供商和Java RIA, Web, J2ME解决方案开发商

2009年2月25日

JComponentPack 3.0 功能介绍

JComponentPack 是一个基于Java SwingGUI类库,一系列可视化的JavaBeans集合,它基于SwingMVC架构,是100%的纯Java类库,它包括20多个Swing 所没有的控件,如EXCEL风格Java的电子表格控件,读取数据库表的Java表格控件,日历控件,类似资源管理器的列表控件,向导框架等等,这些 JavaBeans可以直接拖动到您的图形用户界面,它可提高您的工作效率,加快您的项目开发过程。

功能列表

· JBean应用程序框架

JBean应用程序框架提供了一个标准的Swing应用程序框架,它支持从属性文件创建Actions,创建和动态显示菜单,也支持创建单选按钮,多选按钮,能动态改变按钮状态。它提供了一个资源管理类,能够从定义好的资源文件装载小图标,菜单和按钮的资源。 

JBean应用程序框架包含了一些常用的标准控件,包括打印和打印预览控件,状态栏控件,登陆对话框,反馈对话框,外观改变对话框等。 

JBean应用程序框架包含了一些常用的单元格绘制和编辑器,它们支持通用的数据类型,包括数字,日期,文件,图表,颜色等类型。这些单元格绘制和编辑器也提供了不同的控件支持,包括复选框,下拉框等。

· JComponentSet控件集

JComponentSet是一个Java swing控件集,包括JWizardPane, JListView, Layout Suite (CellLayout, BoxLayout2, CardLayout2, GridLayout2), JDirChooser, JCalendar, JFontChooser, JLinkButton, JSidePane, JSideBar, JImageViewer, XTree, XCheckBox, JCardPane, JGridPane等一系列控件.

· 图形控件

提供了常见的图形, 2D图形和3D图形.

· 图表控件

支持3种不同的图表类型, 分别是饼形图,条形图和线形图.

· 核心公式框架

核心公式框架定义了一个通用的公式框架,包括函数和公式定义,公式解析器等接口。

· JDataGrid核心控件

· 普通文件格式的输入和输出

支持输入和输出多种文件格式,包括csv, html, txt.

· JDataGrid电子表格控件

JDataGrid电子表格控件是了一个Java swing 电子表格控件,提供了基本的功能,如撤销和重做,合并单元格,拼写检查,Excel文件的输入和输出,打印和打印预览等,也包括了复杂的高级功能.

· 电子表格公式

支持许多函数,例如逻辑函数, 日期函数, 数学计算函数, 文本函数, 单元格函数, 和部分的统计函数.

· 高级文件格式的输入和输出

支持输入和输出多种文件格式,包括Excel xls, Excel xml, PDF.

· JDataGrid电子表格JavaFX控件

最新的JDataGrid电子表格控件支持JavaFX平台,新添加了JavaFX控件"DataGrid""DataGridBean",您可以在JavaFX脚本中直接使用这些控件,这些JavaFX控件直接支持最新的JDataGrid电子表格服务器端控件。

· JDataGrid电子表格JavaEE服务器端控件

最新的JDataGrid电子表格服务器端控件能部署在JavaEE应用服务器上,JDataGrid小程序直接支持最新的服务器端控件,您可以通过简单的设置,设置一个服务器端控件的URL,就能读取,保存,下载各种不同格式的电子表格文件,所有的配置在服务器端完成。

· JDataGrid数据库控件

JDataGrid数据库控件是一个能够直接对数据库操作的表格,基于标准的JDBC技术,能够直接操作ResultSetRowSet,并提供如打印和打印预览,多种格式的文件输入和输出的功能.

试用版下载(点击下载

posted @ 2009-04-13 12:11 fralepg 阅读(376) | 评论 (0)编辑 收藏

JComponentPack3.0正式发布

     摘要: 新功能介绍:

  3.0版本添加了最新的JDataGrid电子表格服务器端控件,JDataGrid小程序直接支持最新的服务器端控件,您可以通过简单的设置,设置一个服务器端控件的URL,就能读取,保存,下载各种不同格式的电子表格文件, 所有的配置在服务器端完成。

  3.0版本添加了JDataGrid JavaFX 控件"DataGrid"和"DataGridBean",您可以在JavaFX脚本中直接调用 这些控件,这些JavaFX控件直接支持最新的JDataGrid电子表格服务器端控件。  阅读全文

posted @ 2009-04-10 14:47 fralepg 阅读(223) | 评论 (0)编辑 收藏

介绍JCalendar的新功能

JCalendar new features in JComponentPack

  1. New property to control the action click count
  2. New client property to control the "today” button action behavior
  3. JCalendar works with AComboBox and add new calendar popup icon.

1. New property to control the action click count

JCalendar provides new property named “actionClickCount” since JComponentPack 1.1.0, use this property, you can set the mouse click count to fire the action event, JCalendar adds the following methods:
  JCalendar.getActionClickCount();
  JCalendar.setActionClickCount(int);

2. New client property to control the "today” button action behavior

With this new client property “JCalendar.todayButtonFireActionEventEnabled” since JComponentPack 1.1.0, the JCalendar can fire the action event when the today button clicked.

The above new features is very important when JCalendar working with the AComboBox, the the popup JCalendar make visible, by using the above property, the popup can hidden when use click a "today” button or select a specified day.

3. JCalendar works with AComboBox and add new calendar popup icon.

When AComBoBox set a Date value , the popup icon automatically became a calendar icon, this is a nice feature since JComponentPack 1.1.0, see the screenshot for this feature:

JCalendar - JComponentPack 1.1.0

posted @ 2009-02-26 09:39 fralepg 阅读(663) | 评论 (0)编辑 收藏

介绍JComponentPack产品中的JListView控件


If you want to implements the Windows explorer like feature in Java swing application, the JListView component meets your requirements exactly.

The JListView component support the 5 different view modes: small icon, large icon, list, thumbnails, details, all these view mode can change on the fly, the methods “JListView.setViewMode” can change the view mode of JListView component.

The JListView component have the MVC design concept, a simple TableModel can be provided for it’s data, a simple CellProvider such IconProvider can be provided for it’s icon. Should write a DefaultCellRenderer subclass for its renderer and DefaultCellEditor subclass for it’s editor. The article “Introduce Cell Renderer” introduce why using the DefaultCellRenderer.

The JListView component use a ListSelectionModel as it’s selection model, you can change the selection model’s mode, it support single selection, single interval selection, multiple interval selection, you can use the following methods to get the selected values:

      JListView.getSelectedValue(); // get the lead selection value
       JListView.getSelectedValues(); // get all selected values

The JListView component provides several methods for it’s editing:
       JListView.isEditing(); // determines whether the JListView is being edited.
       JListView.cancelEditing(); // cancel current editing
       JListView.stopEditing(); // stop the current editing and apply the editing value
       JListView.startEditingAtIndex(); // start the editing at the specified index
       JListview.getEditingInex(); // get the current editing object’s index

The com.zfqjava.swing.model and com.zfqjava.swing.cell package have the FileTableModel and FileProvider, it support the directory list and file icon directly, the following code can create a explorer like GUI:

       JListView listView = new JListView();
       listView.setListData(new FileTableModel(new File(System.getProperty("user.home"))));
       listView.setCellRenderer(new FileCellRenderer());
       listView.setCellEditor(new FileCellEditor());

The JListView component also support row sorting, the TableModel you provided for JListView only need implements the ColumnSorter interface, it can support the row sorting automatically, we want to improve this area after upgrade the JRE version to 1.6.

The JListView component provides several important client property:

JListView.rowSelectionAllowed” allow the full row can be selected
JListView.showVerticalLines” shows the vertical lines in details view mode.
JListView.showHorizontalLines” shows the horizontal lines in details view mode.
JListView.backgroundImage” sets the background image for JListView component.

For details, you can view the JListView JavaDoc API documentation.

The JListView also support the Drag and Drop, but in JComponentPack 1.1.0 and early version, implements this feature has trick and tips:

       // get JTable and JList
       BasicListViewUI ui = (BasicListViewUI)listView.getUI();
       JTable table = ui.getTable();
       JList list = ui.getList();
       table.setDragEnabled(true);
       list.setDragEnabled(true);
       TransferHandler th = new TransferHandler() {             
              public int getSourceActions(JComponent c) {
               return COPY;
        }
              protected Transferable createTransferable(JComponent c) {
                  // just a test
                  Object o = listView.getSelectedValue();
                  if(o != null) {
                     return new StringSelection(o.toString());
                  }
                  return null;
              }
           };
       table.setTransferHandler(th);
       list.setTransferHandler(th);

In the upcoming version JComponentPack 1.2.0, we have improved this area, so in the new version, implements the drag and drop feature is very simple:

       listView.setDragEnabled(true);
TransferHandler th = new TransferHandler() {
              public int getSourceActions(JComponent c) {
               return COPY;
        }

              protected Transferable createTransferable(JComponent c) {
                  // just a test
                  Object o = listView.getSelectedValue();
                  if(o != null) {
                     return new StringSelection(o.toString());
                  }
                  return null;
              }
           };
       listView. setTransferHandler(th);


If you want to implements the Windows explorer like feature in Java swing application, the JListView component meets your requirements exactly.

The JListView component support the 5 different view modes: small icon, large icon, list, thumbnails, details, all these view mode can change on the fly, the methods “JListView.setViewMode” can change the view mode of JListView component.

The JListView component have the MVC design concept, a simple TableModel can be provided for it’s data, a simple CellProvider such IconProvider can be provided for it’s icon. Should write a DefaultCellRenderer subclass for its renderer and DefaultCellEditor subclass for it’s editor. The article “Introduce Cell Renderer” introduce why using the DefaultCellRenderer.

The JListView component use a ListSelectionModel as it’s selection model, you can change the selection model’s mode, it support single selection, single interval selection, multiple interval selection, you can use the following methods to get the selected values:

      JListView.getSelectedValue(); // get the lead selection value
       JListView.getSelectedValues(); // get all selected values

The JListView component provides several methods for it’s editing:
       JListView.isEditing(); // determines whether the JListView is being edited.
       JListView.cancelEditing(); // cancel current editing
       JListView.stopEditing(); // stop the current editing and apply the editing value
       JListView.startEditingAtIndex(); // start the editing at the specified index
       JListview.getEditingInex(); // get the current editing object’s index

The com.zfqjava.swing.model and com.zfqjava.swing.cell package have the FileTableModel and FileProvider, it support the directory list and file icon directly, the following code can create a explorer like GUI:

       JListView listView = new JListView();
       listView.setListData(new FileTableModel(new File(System.getProperty("user.home"))));
       listView.setCellRenderer(new FileCellRenderer());
       listView.setCellEditor(new FileCellEditor());

The JListView component also support row sorting, the TableModel you provided for JListView only need implements the ColumnSorter interface, it can support the row sorting automatically, we want to improve this area after upgrade the JRE version to 1.6.

The JListView component provides several important client property:

JListView.rowSelectionAllowed” allow the full row can be selected
JListView.showVerticalLines” shows the vertical lines in details view mode.
JListView.showHorizontalLines” shows the horizontal lines in details view mode.
JListView.backgroundImage” sets the background image for JListView component.

For details, you can view the JListView JavaDoc API documentation.

The JListView also support the Drag and Drop, but in JComponentPack 1.1.0 and early version, implements this feature has trick and tips:

       // get JTable and JList
       BasicListViewUI ui = (BasicListViewUI)listView.getUI();
       JTable table = ui.getTable();
       JList list = ui.getList();
       table.setDragEnabled(true);
       list.setDragEnabled(true);
       TransferHandler th = new TransferHandler() {             
              public int getSourceActions(JComponent c) {
               return COPY;
        }
              protected Transferable createTransferable(JComponent c) {
                  // just a test
                  Object o = listView.getSelectedValue();
                  if(o != null) {
                     return new StringSelection(o.toString());
                  }
                  return null;
              }
           };
       table.setTransferHandler(th);
       list.setTransferHandler(th);

In the upcoming version JComponentPack 1.2.0, we have improved this area, so in the new version, implements the drag and drop feature is very simple:

       listView.setDragEnabled(true);
TransferHandler th = new TransferHandler() {
              public int getSourceActions(JComponent c) {
               return COPY;
        }

              protected Transferable createTransferable(JComponent c) {
                  // just a test
                  Object o = listView.getSelectedValue();
                  if(o != null) {
                     return new StringSelection(o.toString());
                  }
                  return null;
              }
           };
       listView. setTransferHandler(th);



posted @ 2009-02-25 10:56 fralepg 阅读(514) | 评论 (0)编辑 收藏

<2009年2月>
25262728293031
1234567
891011121314
15161718192021
22232425262728
1234567

导航

统计

公告

JComponentPack 3.0正式发布 功能介绍

JComponentPack 是一个基于Java SwingGUI类库,一系列可视化的JavaBeans集合,它基于SwingMVC架构,是100%的纯Java类库,它包括20多个Swing 所没有的控件

试用版下载(点击下载

常用链接

留言簿(1)

随笔档案

文章档案

搜索

最新评论

阅读排行榜

评论排行榜