ChronoGrapher add-on: help please.

Hi everyone,
I am a new here and I have no experience in use of vaadin.
I’ve tried to use this add-on and now have some problems with use:

Widgetset does not contain implementation for org.vaadin.chronographer.ChronoGrapher. Check its @ClientWidget mapping, widgetsets GWT module description file and re-compile your widgetset. In case you have downloaded a vaadin add-on package, you might want to refer to add-on instructions. Unrendered UIDL:
-Unrendered UIDL
-org.vaadin.chronographer.ChronoGrapher(NO CLIENT IMPLEMENTATION FOUND) id=PID58

I have allready checked web.xml and myapp.gwt.xml files:
web.xml have all required dependens
myapp.gwt.xml have this -


Can anyone help me to resolve this problem?
All I am trying to do in this app is just get clean timeline:
import org.vaadin.chronographer.*;
class myapp{
private ChronoGrapher grapher;
priveate void init()
{
–//–//-- creating some crud
grapher = new ChronoGrapher;
addComponent(grapher);
}
–//–//-- some code
}
PS: this is a maven project.
Thanks,
Leonid

Have you recompiled your widgetset after changing the definition file?

Hi again,
I have tried to recompile widget and now I have this printout:

[INFO]
Compiling module ru.mera.teamtracker.ui.widgetset.TeamTrackerWidgetSet
[INFO]
Validating newly compiled units
[INFO]
[ERROR]
Errors in ‘jar:file:/D:/Source/MyApp_REPO/org/vaadin/addons/chronographer/0.0.3/chronographer-0.0.3.jar!/org/vaadin/chronog
rapher/gwt/client/ui/VChronoGrapher.java’
[INFO]
[ERROR]
Line 38: The import com.netthreads.gwt.simile.timeline.client.TimeLineClickHandler cannot be resolved
[INFO]
[ERROR]
Line 55: The constructor TimeLineWidget() is undefined
[INFO]
[ERROR]
Line 72: The method initialise() in the type TimeLineWidget is not applicable for the arguments (int, int)
[INFO]
[ERROR]
Line 74: The method addClickHandler(VChronoGrapher.EventClickHandler) is undefined for the type TimeLine
[INFO]
[ERROR]
Line 90: The method initialise() in the type TimeLineWidget is not applicable for the arguments (int, int)
[INFO]
[ERROR]
Line 124: The method setFirstDayOfWeek(int) is undefined for the type Theme
[INFO]
[ERROR]
Line 163: The method setEventTrackGap(float) is undefined for the type Theme
[INFO]
[ERROR]
Line 167: The method setEventTrackHeight(float) is undefined for the type Theme
[INFO]
[ERROR]
Line 171: The method setEventTrackOffset(float) is undefined for the type Theme
[INFO]
[ERROR]
Line 178: The method setEventInstantIcon(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 182: The method setEventInstantImpreciseColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 187: The method setEventInstantImpreciseOpacity(int) is undefined for the type Theme
[INFO]
[ERROR]
Line 192: The method setEventInstantLineColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 196: The method setEventInstantShowLineForNoText(boolean) is undefined for the type Theme
[INFO]
[ERROR]
Line 201: The method setEventInstantIcon(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 209: The method setEventDurationColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 213: The method setEventDurationImpreciseColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 218: The method setEventDurationImpreciseOpacity(int) is undefined for the type Theme
[INFO]
[ERROR]
Line 223: The method setEventDurationOpacity(int) is undefined for the type Theme
[INFO]
[ERROR]
Line 230: The method setEventLabelInsideColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 235: The method setEventLabelOutsideColor(String) is undefined for the type Theme
[INFO]
[ERROR]
Line 340: The method setOverview(Boolean) is undefined for the type BandInfo
[INFO]
[ERROR]
Line 419: TimeLineClickHandler cannot be resolved to a type
[INFO]
[ERROR]
Line 421: The method onClick(int, int, int, String) of type VChronoGrapher.EventClickHandler must override or implement a supe
rtype method
[INFO]
Scanning for additional dependencies: jar:file:/D:/Source/MyApp_REPO/com/vaadin/vaadin/6.8.1/vaadin-6.8.1.jar!/com/vaadin/terminal/gwt
/client/WidgetSet.java
[INFO]
Computing all possible rebind results for ‘com.vaadin.terminal.gwt.client.WidgetMap’
[INFO]
Rebinding com.vaadin.terminal.gwt.client.WidgetMap
[INFO]
Invoking generator com.vaadin.terminal.gwt.widgetsetutils.EagerWidgetMapGenerator
[INFO]
Detecting Vaadin components in classpath to generate WidgetMapImpl.java …
[ERROR]
фхъ 27, 2012 11:25:43 AM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Searching for paintables…
[ERROR]
фхъ 27, 2012 11:25:45 AM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Search took 1859ms
[INFO]
[WARN]
Widget class org.vaadin.chronographer.gwt.client.ui.VChronoGrapher was not found. The component org.vaadin.chronographer.
ChronoGrapher will not be included in the widgetset.
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.vaadin.ui.AbsoluteLayout
[INFO]
com.vaadin.ui.Accordion
[INFO]
com.vaadin.ui.Audio
[INFO]
com.vaadin.ui.Button
[INFO]
com.vaadin.ui.CheckBox
[INFO]
com.vaadin.ui.ComboBox
[INFO]
com.vaadin.ui.CssLayout
[INFO]
com.vaadin.ui.CustomComponent
[INFO]
com.vaadin.ui.CustomLayout
[INFO]
com.vaadin.ui.DateField
[INFO]
com.vaadin.ui.DragAndDropWrapper
[INFO]
com.vaadin.ui.Embedded
[INFO]
com.vaadin.ui.Form
[INFO]
com.vaadin.ui.FormLayout
[INFO]
com.vaadin.ui.GridLayout
[INFO]
com.vaadin.ui.HorizontalLayout
[INFO]
com.vaadin.ui.HorizontalSplitPanel
[INFO]
com.vaadin.ui.InlineDateField
[INFO]
com.vaadin.ui.Label
[INFO]
com.vaadin.ui.Link
[INFO]
com.vaadin.ui.ListSelect
[INFO]
com.vaadin.ui.MenuBar
[INFO]
com.vaadin.ui.NativeButton
[INFO]
com.vaadin.ui.NativeSelect
[INFO]
com.vaadin.ui.OptionGroup
[INFO]
com.vaadin.ui.OrderedLayout
[INFO]
com.vaadin.ui.Panel
[INFO]
com.vaadin.ui.PasswordField
[INFO]
com.vaadin.ui.PopupView
[INFO]
com.vaadin.ui.ProgressIndicator
[INFO]
com.vaadin.ui.RichTextArea
[INFO]
com.vaadin.ui.Select
[INFO]
com.vaadin.ui.Slider
[INFO]
com.vaadin.ui.SplitPanel
[INFO]
com.vaadin.ui.TabSheet
[INFO]
com.vaadin.ui.Table
[INFO]
com.vaadin.ui.TextArea
[INFO]
com.vaadin.ui.TextField
[INFO]
com.vaadin.ui.Tree
[INFO]
com.vaadin.ui.TreeTable
[INFO]
com.vaadin.ui.TwinColSelect
[INFO]
com.vaadin.ui.Upload
[INFO]
com.vaadin.ui.UriFragmentUtility
[INFO]
com.vaadin.ui.VerticalLayout
[INFO]
com.vaadin.ui.VerticalSplitPanel
[INFO]
com.vaadin.ui.Video
[INFO]
com.vaadin.ui.Window
[INFO]
org.vaadin.teemu.wizards.WizardProgressBar
[INFO]
Done. (2seconds)

I guess this is the reason why I have get previous issue. Can anyone help me please? What I need to do to solve this issue?

It looks as if you were using versions of ChronoGrapher and Vaadin that are not compatible with each other, they should be compatible based on what I see.

Try with the latest Vaadin 6.8.x. Also, make sure you don’t have extra conflicting versions of Vaadin or GWT somewhere on your classpath.

I have checked my vaadin version and it is 6.8.1 but add-on need 6.8.5. Now I have a question how am I supposed to upgrade it? I have downloaded *.jar file and added it in project but when recompiling still does not work and I can see from it that it use vaadin 6.8.1

I am not sure that something have changed but now I have this while trying to recompile widget:
[ERROR]
фхъ 28, 2012 1:41:02 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Widgetsets found from classpath:
[ERROR]
org.vaadin.teemu.wizards.WizardsforvaadinWidgetset in jar:file:D:/Source/MyApp_REPO/org/vaadin/addons/wizards-for-vaadin/0.4.5/w
izards-for-vaadin-0.4.5.jar!/
[ERROR]
com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:D:/Source/MyApp_REPO/com/vaadin/vaadin/6.8.1/vaadin-6.8.1.jar!/
[ERROR]
com.vaadin.addon.tableexport.widgetset.Tableexport_for_vaadinWidgetset in jar:file:D:/Source/TeamTracker_REPO/org/vaadin/addons/tablee
xport/1.3.0/tableexport-1.3.0.jar!/
[ERROR]
ru.mera.teamtracker.ui.widgetset.TeamTrackerWidgetSet in file://D/Source/MyApp/myapp-web/myapp-ui/src/main/java
[ERROR]
org.vaadin.chronographer.gwt.ChronoGrapherWidgetSet in jar:file:D:/Source/MyApp_REPO/org/vaadin/addons/chronographer/0.0.3/chron
ographer-0.0.3.jar!/
[ERROR]

[ERROR]
фхъ 28, 2012 1:41:02 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Search took 0ms
[INFO]

I have tried to change vaadin jar file in buildpath but it doesn’t work. )=

Can anyone help me please?
Lets start from begining:
1)I have existing maven project
2)I have this add-on ChronoGrapher
3)I download chronographer.jar and gwt-simile-timeline.jar
4)next making mvn deploy-file (both chronographer and gwt-simile-timeline)
5)next making mvn install-file with groops Id and artifacts
6)next adding dependancys in pom.xml
7)mvn clean install BUILD SUCCESS
8)mvn -e clean package jetty:run -Dspring.profiles.active=development -P recompileWidgetset ← and here I have errors
Where is my mistake?

Hello again,
I have found that there is no TimeLineClickHandler.java in gwt-simile-timeline.jar
Maybe this is the issue?

Merry Christmas & Happy New Year,
Leonid

Hi Leonid, sorry that I haven not answered your questions before.

Lets first make sure that your project configuration is working.

  1. Create a Vaadin project with maven archetype “vaadin-archetype-sample” version 1.7.2

  2. Update the Vaadin version of your pom.xml file to the newest (6.8.x) one: “<vaadin.version>6.8.7</vaadin.version>”

  3. Add the newest Chronographer version dependency into your pom.xml

<dependency>
   <groupId>org.vaadin.addons</groupId>
   <artifactId>chronographer</artifactId>
   <version>0.0.4</version>
</dependency>

3.b Add also dependency to gson:

<dependency>
		<groupId>com.google.code.gson</groupId>
		<artifactId>gson</artifactId>
		<version>2.1</version>
	</dependency>
  1. Create a gwt.xml file for your project. For instance if your default packages are named as foo.bar, then create directory foo.bar.gwt and add file name FooWidgetSet.gwt.xml there. Content for this file is given below:

<module>
    <inherits name="org.vaadin.chronographer.gwt.ChronoGrapherWidgetSet" />
</module>

4.b Modify your web.xml’s vaadin servlet to have reference this widgetset and also for customized VaadinServlet name ChronographerServlet. See example below:


...
<servlet>
        <servlet-name>Vaadin Application Servlet</servlet-name>
        [b]
<servlet-class>org.vaadin.chronographer.ChronographerServlet</servlet-class>
[/b]
        <init-param>
            <description>Vaadin application class to start</description>
            <param-name>application</param-name>
            <param-value>foo.bar.FooApplication</param-value>
        </init-param>
        <init-param>
            <param-name>widgetset</param-name>
            <param-value>foo.bar.gwt.FooWidgetSet</param-value>
        </init-param>
    </servlet>
...
  1. Compile the widgetset: mvn gwt:compile (or by “mvn clean” and “mvn install”)

Could you, please, check whether your project work after these steps?

Cheers,
Johannes

-Edited: added gson dependency-
-Edited: updated instructions-
-Edited: added custom servlet configuration-

Ps. never thought it would require that much configuration :frowning:

Hi Johannes,

now I have this:
Failed to load the widgetset: /myApp-ui/VAADIN/widgetsets/org.vaadin.chronographer.gwt.ChronoGrapherWidgetSet
/org.vaadin.chronographer.gwt.ChronoGrapherWidgetSet.nocache.js?1357716800792

Compilations process and widget recompilation are successful, but when I am trying to open localhost (mvn jetty:run) I have that message.

Thanks,
Leonid

Hi Leonid,

Yes, you are right. I forgotted one more thing: you need your own *.gwt.xml file also in the project setup… I’ll update the instructions post above…

Johannes

I added a quick start page also in my git hub


https://github.com/johannest/similetimelineforvaadin/wiki/Quick-Start-with-ChronoGrapher-(using-maven)

#johannest

Thanks Johannes, that helped, message is gone. But now I have a clean window without any objects in it and there supposed to be a table at least.
Here are my web.xml and *gwt.xml

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
    <display-name>Experiment One</display-name>
    <context-param>
        <description>Vaadin production mode</description>
        <param-name>productionMode</param-name>
        <param-value>false</param-value>
    </context-param>
    
    <!-- Vaadin servlet definition and mapping -->
    <servlet>
        <servlet-name>Experiment One Servlet</servlet-name>
        <servlet-class>com.vaadin.terminal.gwt.server.ApplicationServlet</servlet-class>
        <init-param>
            <description>Main class for the application</description>
            <param-name>application</param-name>
            <param-value>ru.example.experimentone.ui.ExperimentOneApplication</param-value>
        </init-param>
        <init-param>
            <param-name>widgetset</param-name>
            <param-value>ru.example.experimentone.ui.widgetset.ExperimentOneWidgetSet</param-value>
        </init-param>
    </servlet>
    <servlet-mapping>
        <servlet-name>Experiment One Servlet</servlet-name>
        <url-pattern>/*</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
        <servlet-name>Experiment One Servlet</servlet-name>
        <url-pattern>/VAADIN/*</url-pattern>
    </servlet-mapping>
    
    <!-- Spring integration -->
    
    <!-- Context configuration file location -->
    <context-param>
        <param-name>contextConfigLocation</param-name>
        <param-value>classpath:applicationContext.xml</param-value>
	</context-param>
	<!-- Default spring profile name -->
	<context-param>
        <param-name>spring.profiles.default</param-name>
        <param-value>production</param-value>
    </context-param>
    <!-- Spring listeners -->
	<listener>
	    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
	</listener>
	<listener>
	    <listener-class>org.springframework.web.context.request.RequestContextListener</listener-class>
	</listener> 
</web-app>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE module PUBLIC
    "-//Google Inc.//DTD Google Web Toolkit 1.7.0//EN"
    "http://google-web-toolkit.googlecode.com/svn/tags/1.7.0/distro-source/core/src/gwt-module.dtd">
<module>
    <inherits name="org.vaadin.teemu.wizards.WizardsforvaadinWidgetset" />
    <inherits name="com.vaadin.terminal.gwt.DefaultWidgetSet" />
    <inherits name="com.vaadin.addon.tableexport.widgetset.Tableexport_for_vaadinWidgetset" />
    <inherits name="org.vaadin.chronographer.gwt.ChronoGrapherWidgetSet" />
    <inherits name="org.vaadin.vaadinvisualizations.widgetset.VaadinvisualizationApplicationWidgetset" />
</module>

Leonid

Hi again

I have tryed to do next:
1)in my existing maven project create new calss TestDiagramm (just copy-paste from examples)
2)in class where it must be called just as in example create TabSheet, then tabsheet.addTab(TestDiagramm, “TEST”) and after that addComponent(tabsheet)
All recompilation process gone well, no errors.
But when I opened localhost through jetty and then opened tab where table+some charts + new diagramm supposed to be - just clean tab without any objects, even old objects table and charts have gone.
Could anyone tell me where is the problem?
PS: I have this output from server logs:

Cronograma.paintContent
..structure
[
  {
    "themesIndex": 0,
    "firstDayOfWeek": 1,
    "event": {
      "instant": {
        "icon": "js/api/images/dull-green-circle.png",
        "lineColor": "black",
        "impreciseColor": "gray",
        "impreciseOpacity": 20,
        "showLineForNoText": false
      },
      "duration": {
        "color": "red",
        "opacity": 30,
        "impreciseColor": "gray",
        "impreciseOpacity": 20
      },
      "label": {
        "insideColor": "green",
        "outsideColor": "#554400"
      }
    }
  },
  {
    "themesIndex": 1,
    "firstDayOfWeek": 1,
    "event": {
      "instant": {
        "icon": "js/api/images/blue-mark.png",
        "lineColor": "black",
        "impreciseColor": "red",
        "impreciseOpacity": 20,
        "showLineForNoText": false
      },
      "duration": {
        "impreciseColor": "red",
        "impreciseOpacity": 40
      },
      "label": {
        "insideColor": "green",
        "outsideColor": "#554400",
        "width": 5
      }
    }
  }
]
...theme

Leonid

Hi again,

I have to apologize again… I forgotted one more configuration :frowning: :
You have to also use my custom vaadin servlet in your web.xml intead of standard VaadinServlet.

<servlet-class>org.vaadin.chronographer.ChronographerServlet</servlet-class>

I hope that was the last configuration needed! I’ll update the instruction post above and also the quick start in the GitHub.

#johannest

Hi Johannes,
I will try this one :slight_smile:
Also I found that this is a known issue for “newcommers” and that this can be fixed just like in your example:

@Override
    public void init() {
        setMainWindow(main);
        main.setDebugId("timeline-mainwindow");

        createTabSheet();

        [color=#ff0000]
main.setSizeFull();
        main.setImmediate(true);
        main.getContent().setDebugId("timeline-mainwindow-content");
        main.addComponent(tabsheet);
[/color]
    }

But unfortunatly I can not use this code because parent window initialized in another class and I am currently trying to add diagramm into “chield” layout (well if I can then I have a question - how :slight_smile: because I do not know). I am not looking for easy ways :slight_smile:
So again I will try to add
Have a good day.
PS: sync issues after adding . It happend because other modulse use standart .
Thanks,
Leonid

I am trying to implement timeline for vacations planning. I noticed that Chronographer draws events in free (non-crossing with other events) places of the lines. If required time period is free in upper line then the event is drawn there. But if it is already busy then the event is drawn on below line.

Is it possible to draw required (e.g., non-crossing, sorted by name) events on the same line with Chronographer?

PS: This add-on works without any problems under IE but in chrome I have sync issues when I am trying to open any tag or click any button after ChronoGraph was loaded.
Thanks,
Leonid

Hi Leonid!

I have to see that Chrome issue, thanks for reporting!

About your question, I think that only way to control how the events are painted is to modify the javascript sources. Js-sources are under org.vaadin.chronographer.gwt public/js/api/scripts… I suggest that you could trace the correct place using the Firebug’s javascript breakpoint on the *-painter.js files…

#johannest

Hi Johannes,

Thanks for your help.
Here is a printout from server

Cronograma.paintContent
..structure
...events
 эт 22, 2013 10:27:26 AM com.vaadin.terminal.gwt.server.AbstractApplicationServlet serveStaticResourcesInVAADIN
INFO: Requested resource [VAADIN/widgetsets/com.example.teamtracker.ui.widgetset.TeamTrackerWidgetSet/vaadin-chart/styles.css]
 not found from filesystem o
r through class loader. Add widgetset and/or theme JAR to your classpath or add files to WebContent/VAADIN folder.
Cronograma.paintContent
Cronograma.paintContent
 эт 22, 2013 10:27:33 AM com.vaadin.terminal.gwt.server.AbstractCommunicationManager handleVariableBurst
WARNING: Warning: Ignoring variable change for non-existent component, VAR_PID=PID68
 эт 22, 2013 10:27:33 AM com.vaadin.terminal.gwt.server.AbstractCommunicationManager handleVariableBurst
WARNING: Warning: Ignoring variable change for non-existent component, VAR_PID=PID68
 эт 22, 2013 10:27:33 AM com.vaadin.terminal.gwt.server.AbstractCommunicationManager handleVariableBurst
WARNING: Warning: Ignoring variable change for non-existent component, VAR_PID=PID52
 эт 22, 2013 10:27:33 AM com.vaadin.terminal.gwt.server.AbstractCommunicationManager handleVariableBurst
WARNING: Warning: Ignoring variable change for non-existent component, VAR_PID=PID77

Steps:
1)run jetty
2)open localhost
3)open tab with ChronoGrapher - and it is shown and now problems or issue here
4)after that trying to open another tab or just click some buttons like “refresh” or “show table” I’m getting message in red lable “Out of sync” in the top of page

Regards,
Leonid

Hi Johannes,
I have found out that I need to use trackNum property of each event but I have not found methods setTrackNum or getTrackNum in TimelineEvent. I have no access to your project source-files so could you please check this trackNum and maybe add methods in ChronoGrapher which will allow as edit this property for new events?

Thanks,
Leonid