Directory

← Back

Toolkit Productivity Tools

Productivity helper library for fast day-to-day vaadin-based apps development

Author

Rating

Popularity

<100

Toolkit Productivity Tools is an pure server-side extension to a great server-side rich UI Vaadin framework, providing extra collection of common patterns, widgets and utilities you usually use in almost any vaadin-based web application. This library aims to help you save development time by reusing most commonly used patterns and things:

  • Built-in fast PDF viewer - let your application users to browse thousands of pages PDF documents even without downloading them to local computer - pages are displayed online as per reading. See the on-line demo for details !

  • Built-in ThreadLocal pattern allows to get your app instance from any piece of code, even from spawned threads via simple getTPTApplication static call.

  • Built-in internationalization support (i18n) - make your app messages and custom layout files internatioalized in seconds. Moreover, i18n files are based on standard java property files, not limited in count and structure and resides in your theme folder for easy editing even in a running deployed app !

  • Built-in views-based navigational component allows you to create iphone-os-like views and naviagte between them either programmatically or manually via URL - built-in support for URIFragmentUtility is present ! You can even pass parameters to your views and let your views to listen to navigation events !

  • Built-in wrapper for lazy loading or long initializing views or components, easily letting developer to avoid client browser stucks and red wheel of death ;)

  • Built-in standard dialogs - message dialog, confirmation dialog, question dialog, download dialog and custom dialog - created and invoked with a single statement !

  • Several small but useful widgets to save your coding time: captcha component, sizer to quickly insert dynamic margins, message panel, lazy loading panel

  • Easy to use - even no widgetset compilation required - all code is server-side only.

TPT has no external dependencies except as for PDF viewer, where open source edition of IcePDF is used internally for page rendering.

TPT is also a pure server-side - it does not contain any custom widgetsets - just a server-side .jar file. This is especially important for those who does not use Eclipse and do not have automatic widgetset compilation feature.

Sample code

/** provide translation files in standard java .property files in your theme folder **/
main.windows.logo=TPT
main.window.version=Version %s
developer.handbook=Download developer book



/** use translations in your app code **/
Label h1 = new Label ( TM.get ( "main.window.logo") );
h1.setStyleName ( "h1" );

Label h2 = new Label ( TM.get("main.window.version", "1.1") );
Link manual = new Link ( TM.get("developer.handbook"), new ThemeResource ( "files/handbook.pdf" ) );
DocumentViewer viewer = new DocumentViewer();
viewer.loadDocument ( new PdfDocument ( new File ( "/path/to/doc.pdf" ) ) );

addComponent ( viewer );
addComponent ( new TPTMessagePanel ( "Hello World !" ) );
final OptionDialog dlg = new OptionDialog ( TPTApplication.getCurrentApplication () );

dlg.showMessageDialog ( "Hello", "That's a deal. Period.", new OptionDialog.OptionDialogResultListener () 
{
  public void dialogClosed ( OptionKind closeEvent )
  {
    TPTApplication.getCurrentApplication ().getMainWindow ().showNotification ( "That's a deal !");
  }
});
final OptionDialog dlg = new OptionDialog ( TPTApplication.getCurrentApplication () );

dlg.showConfirmationDialog ( "Attention please !", "Are you sure to exit ?", new OptionDialog.OptionDialogResultListener () 
 {
  public void dialogClosed ( OptionKind closeEvent )
  {
    TPTApplication.getCurrentApplication ().getMainWindow ().showNotification ( "TYou answered: " + closeEvent.name ());
  }
});

Compatibility

(Loading compatibility data...)

Was this helpful? Need more help?
Leave a comment or a question below. You can also join the chat on Discord or ask questions on StackOverflow.

Version

IMPORTANT: If you're using CDI/JEE6 in your TPT-powered Vaadin application, please read this - http://vaadin.com/forum/-/message_boards/message/161629

1.1.1 is a maintenance release of TPT:

  • Fixed issues: #4, #5, #6, thanks for all who reported and sent patches !
  • Removed tpt-demo.war from main package and moved as optional link at right to reduce download size.
  • Removed optional jar files from IcePDF OpenSource edition bundled package to reduce download size.
  • DocumentViewer has now the IcePDF deps protection code - if IcePDF files are not present in the classpath, it will render an appropriate message instead of throwing NoClassDefFound error.
  • Dependency jar files are also copied to distribution "libs" folder to be more visible.
  • i18n translation files should be plain text utf-8 files now - no native2ascii required anymore (according to issue #6)
  • Added dependencies section into the developer handbook to more transparetly describe the external dependencies.
Released
2010-04-26
Maturity
STABLE
License
Apache License 2.0

Compatibility

Framework
Vaadin 6.2+
Vaadin 6.3+ in 1.1.0
Vaadin 6.5+ in 1.2.0
Browser
Browser Independent

Vaadin Add-on Directory

Find open-source widgets, add-ons, themes, and integrations for your Vaadin application. Vaadin Add-on Directory
The channel for finding, promoting, and distributing Vaadin add-ons.
Online