af7336360a06e3805af97c6f3d9ec17c288f3db0
[hooke.git] / hooke / ui / gui / panel / welcome.py
1 # Copyright (C) 2010-2011 W. Trevor King <wking@drexel.edu>
2 #
3 # This file is part of Hooke.
4 #
5 # Hooke is free software: you can redistribute it and/or modify it
6 # under the terms of the GNU Lesser General Public License as
7 # published by the Free Software Foundation, either version 3 of the
8 # License, or (at your option) any later version.
9 #
10 # Hooke is distributed in the hope that it will be useful, but WITHOUT
11 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 # or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General
13 # Public License for more details.
14 #
15 # You should have received a copy of the GNU Lesser General Public
16 # License along with Hooke.  If not, see
17 # <http://www.gnu.org/licenses/>.
18
19 """Welcome panel for Hooke.
20 """
21
22 import wx
23
24 from . import Panel
25
26
27 class WelcomeWindow (wx.html.HtmlWindow):
28     def __init__(self, *args, **kwargs):
29         super(WelcomeWindow, self).__init__(self, *args, **kwargs)
30         lines = [
31             '<h1>Welcome to Hooke</h1>',
32             '<h3>Features</h3>',
33             '<ul>',
34             '<li>View, annotate, measure force files</li>',
35             '<li>Worm-like chain fit of force peaks</li>',
36             '<li>Automatic convolution-based filtering of empty files</li>',
37             '<li>Automatic fit and measurement of multiple force peaks</li>',
38             '<li>Handles force-clamp force experiments (experimental)</li>',
39             '<li>It is extensible through plugins and drivers</li>',
40             '</ul>',
41             '<p>See the <a href="%s">DocumentationIndex</a>'
42             % 'http://code.google.com/p/hooke/wiki/DocumentationIndex',
43             'for more information</p>',
44             ]
45         ctrl.SetPage('\n'.join(lines))
46
47 class WelcomePanel (Panel, wx.Panel):
48     def __init__(self, callbacks=None, **kwargs):
49         super(WelcomePanel, self).__init__(
50             name='welcome', callbacks=callbacks, **kwargs)
51         self._c = {
52             'window': WelcomeWindow(
53                 parent=self,
54                 size=wx.Size(400, 300)),
55             }