summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Ward <ian@excess.org>2014-01-02 21:28:49 -0500
committerIan Ward <ian@excess.org>2014-01-02 21:28:49 -0500
commit8aaf189dd850ab801e32228429d7ff884d8dab08 (patch)
tree35e8f2761149b30a384559d6735857aaeb6839eb
parent92a595a8eaf8b88fab3cfd23d4fc67c5851d0672 (diff)
downloadurwid-8aaf189dd850ab801e32228429d7ff884d8dab08.tar.gz
docs: edit.py example
-rwxr-xr-xdocs/examples/edit.py8
-rw-r--r--docs/examples/edit.py.xdotool2
-rw-r--r--docs/examples/edit_text.txt11
-rw-r--r--docs/examples/index.rst12
l---------docs/examples/real_edit.py1
-rw-r--r--docs/examples/tour3.pngbin3446 -> 0 bytes
-rw-r--r--docs/examples/tour4.pngbin3369 -> 0 bytes
7 files changed, 31 insertions, 3 deletions
diff --git a/docs/examples/edit.py b/docs/examples/edit.py
new file mode 100755
index 0000000..7eacc86
--- /dev/null
+++ b/docs/examples/edit.py
@@ -0,0 +1,8 @@
+#!/usr/bin/env python
+
+import sys
+import os
+import real_edit
+
+real_edit.EditDisplay(os.path.join(
+ os.path.dirname(sys.argv[0]), 'edit_text.txt')).main()
diff --git a/docs/examples/edit.py.xdotool b/docs/examples/edit.py.xdotool
new file mode 100644
index 0000000..70ba7a8
--- /dev/null
+++ b/docs/examples/edit.py.xdotool
@@ -0,0 +1,2 @@
+windowsize --usehints $RXVTWINDOWID 39 20
+key --window $RXVTWINDOWID Return Return a d d i n g space s o m e space t e x t space
diff --git a/docs/examples/edit_text.txt b/docs/examples/edit_text.txt
new file mode 100644
index 0000000..c0947b3
--- /dev/null
+++ b/docs/examples/edit_text.txt
@@ -0,0 +1,11 @@
+替洼渎溏潺瀚灯烫虫调达逯遘醋长闫阚顺驼髓
+공곽껫끓뇽늙등뗍뛴룸많맹뫘볶
+ტექსტების დამუშავებასა და მრავალენოვან კომპიუტერულ სისტემებში.
+ ╔══════════════════════╗
+ ║ • “smart quotes” ║
+ ║ ╭─────────╮ ║
+ ║ • euro: │ € 14.95 │ ║
+ ║ ╰─────────╯ ║
+ ╚══════════════════════╝
+Math: ∮ E⋅da = Q, n → ∞, ∑ f(i) = ∏ g(i), ∀x∈ℝ: ⌈x⌉ = −⌊−x⌋, α ∧ ¬β = ¬(¬α ∨ β)
+
diff --git a/docs/examples/index.rst b/docs/examples/index.rst
index a85b7f1..75333d6 100644
--- a/docs/examples/index.rst
+++ b/docs/examples/index.rst
@@ -14,7 +14,6 @@ tour.py
.. image:: tour1.png
.. image:: tour2.png
-.. image:: tour4.png
A simple example showing how many of the standard widgets may be arranged
on the screen
@@ -23,16 +22,23 @@ on the screen
graph.py
--------
-.. image:: graph1.png
.. image:: graph2.png
A demonstration of the BarGraph widget and alarms used for animation
+edit.py
+-------
+
+.. image:: edit1.png
+.. image:: edit2.png
+
+A simple text editor with lazy loading
+
+
browse.py
---------
-.. image:: browse1.png
.. image:: browse2.png
A lazy directory browser with file selection, tree-view, custom widgets
diff --git a/docs/examples/real_edit.py b/docs/examples/real_edit.py
new file mode 120000
index 0000000..16bf719
--- /dev/null
+++ b/docs/examples/real_edit.py
@@ -0,0 +1 @@
+../../examples/edit.py \ No newline at end of file
diff --git a/docs/examples/tour3.png b/docs/examples/tour3.png
deleted file mode 100644
index 113f1e9..0000000
--- a/docs/examples/tour3.png
+++ /dev/null
Binary files differ
diff --git a/docs/examples/tour4.png b/docs/examples/tour4.png
deleted file mode 100644
index d90a368..0000000
--- a/docs/examples/tour4.png
+++ /dev/null
Binary files differ