File: README.md

package info (click to toggle)
witty 3.2.1-2%2Bdeb7u1
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 70,436 kB
  • sloc: cpp: 117,095; ansic: 77,999; xml: 7,564; sh: 1,037; perl: 208; makefile: 144; java: 86; sql: 14
file content (32 lines) | stat: -rw-r--r-- 1,386 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
Simplechat example
------------------

The simplechat example is a simple multi-user client + server. It is
simple in many ways, including the constraint that all sessions run in
the same process (it does not use inter-process communication), and
that the client does not have any advanced functions.

The example can be run as a plain Wt application, but also as a widget
set widget, which is a popup chat box that sits in the bottom right of
the browser window, and can be integrated easily in another
website. See the [blog post](http://www.webtoolkit.eu/wt/blog/2010/12/17/widgetset_mode_and_cross_origin_requests) for more information.

How to run
----------

See the README in the parent directory.

What it illustrates
-------------------

- how to use server push, and post events to sessions using
  WServer::post() how to reuse a single widget to have two different
- UI experiences (as a normal widget, or as a compact real-estate conserving
  widget for the chat popup)
- how Wt supports Cross-Origin requests to implement widget set mode
- the use of layout managers (`WVBoxLayout` and `WHBoxLayout`)
- how to play small UI sounds using `WSound`
- how to connect client-side JavaScript to a signal, to react to certain events
- how to implement a method in client-side JavaScript using
  `implementJavaScript()`
- how to safely render user-entered HTML without risking XSS