# HG changeset patch
# User Tim Dumol <tim@timdumol.com>
# Date 1256357250 -28800
# Node ID 6fa6cce9bd448c5350b2a3014981a68244470c59
# Parent  5f1705b928fce20a8ce1f546956a1223da8a6f88
#7269 Reduces/replaces table layouts with css layouts.

diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/account_settings.css
--- a/sagenb/data/sage/css/account_settings.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/account_settings.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,60 +1,43 @@
-@import url('/css/reset.css');
-
+@import url('/css/reset.css')[];
 html {
-    font-size:100.1%
-}
+  font-size: 100.1%; }
 
 body {
-    font:100%/1.4 Arial, Helvetica, sans-serif
-}
+  font: 100%/1.4 Arial, Helvetica, sans-serif; }
 
 h1 {
-    background:#DCDCDC;
-    border-bottom:1px solid #CCC;
-    font-size:2em;
-    padding:0 5px
-}
+  background: #DCDCDC;
+  border-bottom: 1px solid #CCC;
+  font-size: 2em;
+  padding: 0 5px; }
 
 #buttons {
-    background:#DCDCDC;
-    padding:5px
-}
+  background: #DCDCDC;
+  padding: 5px; }
 
 h2 {
-    font-size:1.5em
-}
+  font-size: 1.5em; }
 
 .section {
-    border-bottom:1px solid #CCC;
-    padding:5px
-}
-
+  border-bottom: 1px solid #CCC;
+  padding: 5px; }
 .section > div {
-    max-width:350px;
-    text-align:right
-}
+  max-width: 350px;
+  text-align: right; }
 
 table {
-    margin-left: auto;
-    margin-right: auto;
-}
+  margin-left: auto;
+  margin-right: auto; }
 
 tr {
-    height: 2.0em;
-}
+  height: 2.0em; }
 
 td {
-    padding-left:5px
-}
-
+  padding-left: 5px; }
 td.error {
-    color: red;
-}
-
+  color: red; }
 td.updated {
-    color: green;
-}
+  color: green; }
 
 input.c1 {
-    width:200px
-}
+  width: 200px; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/main.css
--- a/sagenb/data/sage/css/main.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/main.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,310 +1,222 @@
-{#
-INPUT:
-- ``color_theme`` -- a string denoting the color scheme to use
-- ``color1`` -- a string denoting an HTML css color code (takes precendence over ``color_theme``)
-- ``color2`` -- a string denoting an HTML css color code (takes precendence over ``color_theme``)
-#}
+body {
+  background-color: white; }
+body.worksheet-online {
+  margin-bottom: 80%; }
 
-{%- if (not color1) or (not color2) %}
-    {%- if color_theme == "grey" %}
-        {%- set color1 = "#aaa" %}
-        {%- set color2 = "#888" %}
-    {%- elif color_theme == "gmail" %}
-        {%- set color1 = "#c3d9ff" %}
-        {%- set color2 = "#b5edbc" %}
-    {%- else %}
-        {%- set color1 = "#dcdcdc" %}
-        {%- set color2 = "#ccc" %}
-    {%- endif %}
-{%- endif %}
-
-body {
-  background-color: white;
-}
-
-body.worksheet-online {
-  margin-bottom: 80%;
-}
-    
-div.hidden {
-  display:none;
-}
-span.hidden{
-  display:none;
-}
+.hidden {
+  display: none; }
 
 div.fivepix {
-  height:5px;
-}
+  height: 5px; }
 
-textarea.hidden {
-   display:none;
-}
+/* ****** Top Bar (Banner, controls, etc.) ******** */
+div.banner {
+  background-color: white;
+  font-family: sans-serif;
+  font-size: 18px;
+  text-decoration: none;
+  color: #1950c8;
+  float: left; }
+div.banner a.banner {
+  text-decoration: none;
+  border: none;
+  margin-top: 2px;
+  float: left; }
 
-pre.hidden {
-   display:none;
-}
+a.banner:visited {
+  color: #1950c8; }
 
-/**** TOP CONTROL BAR ************************/
+div.banner a.banner img {
+  text-decoration: none;
+  border: none;
+  margin-top: 2px; }
+div.banner span {
+  float: left; }
+div.banner div.version {
+  float: left;
+  clear: left;
+  font-size: xx-small;
+  text-indent: 13px;
+  color: black; }
+div#controls {
+  height: 0.8em;
+  margin-top: -0.8em;
+  position: absolute;
+  top: 50%;
+  right: 0;
+  clear: right; }
+div#controls .username {
+  float: left; }
+div#controls .usercontrol {
+  float: left;
+  color: #112abb;
+  padding: 0.6ex 1ex;
+  font-size: 14px;
+  border-right: 1px solid #000; }
+div#controls .usercontrol:last-child {
+  border-right: 0;
+  padding-right: 0.6ex; }
+div#controls a.usercontrol {
+  text-decoration: underline; }
+div#controls a.usercontrol:hover {
+  cursor: pointer; }
+div#top-bar {
+  position: relative;
+  padding: 10px 5px;
+  overflow: auto; }
 
-div.top_control_bar {
-   z-index: 0;
-   background-color: white;
-   position: fixed;
-   left: 0px;
-   width: 100%;
-   top: 0px;
-   padding-left: 2ex;
-}
+hr.usercontrol {
+  clear: both;
+  float: left; }
+
+div#usercontrols {
+  clear: both;
+  border-top: 1px solid #c9d7f1;
+  border-bottom: 1px solid #c9d7f1;
+  padding: 10px; }
+div#worksheet-list-controls {
+  padding: 10px;
+  float: left;
+  clear: both; }
+div#worksheet-list-controls div.action-buttons {
+  float: left; }
+div#worksheet-list-controls div.folders {
+  float: left;
+  clear: right;
+  margin-left: 100px; }
+
+/* ******* Top Control Bar (Worksheets)  ********** */
+#worksheet-bar {
+  overflow: hidden;
+  clear: both; }
+#worksheet-bar a.worksheet_title {
+  text-decoration: none;
+  font-size: 20px;
+  font-family: arial;
+  font-weight: bold;
+  color: #000000; }
+#worksheet-bar a.worksheet_title:hover {
+  background-color: #ffffcc;
+  cursor: pointer; }
+#worksheet-bar div.worksheet_title {
+  float: left;
+  clear: left;
+  padding-left: 1em;
+  background-color: #ffffff;
+  color: black;
+  margin-bottom: 0.5em; }
+#worksheet-bar #save-discard-buttons {
+  float: right;
+  clear: right; }
+#worksheet-bar #worksheet-menu {
+  float: left;
+  clear: left;
+  margin-bottom: 0.25em; }
+#worksheet-bar #share-publish-buttons {
+  float: right;
+  clear: right; }
+#worksheet-bar #share-publish-buttons a.print-link {
+  color: #112abb;
+  text-decoration: underline;
+  margin-right: 0.5em; }
+#worksheet-bar #share-publish-buttons a.print-link img {
+  margin-right: 0.3em; }
 
 span.control_commands {
-   position: fixed;
-   top:1ex;
-   right:1ex;
-   text-align:right;
-   color:blue;   
-   font-weight:normal;   
-   font-family:arial;
-   font-size:12px;
-/*    text-decoration:underline; */
-}
-
+  position: fixed;
+  top: 1ex;
+  right: 1ex;
+  text-align: right;
+  color: blue;
+  font-weight: normal;
+  font-family: arial;
+  font-size: 12px; }
 span.worksheet_control_commands {
-   position: relative;
-   top:0px; 
-   right:0px;
-   text-align:right;
-   color:blue;   
-   font-weight:normal;   
-   font-family:arial;
-   font-size:12px;
-   padding:5px;
-}
+  position: relative;
+  top: 0px;
+  right: 0px;
+  text-align: right;
+  color: blue;
+  font-weight: normal;
+  font-family: arial;
+  font-size: 12px;
+  padding: 5px; }
 
 div.slide_control_commands {
-   float:right;
-   position: fixed;
-   width:500px;
-   top:1ex;
-   right:45%;
-   text-align:right;
-   color:blue;   
-   font-weight:normal;   
-   font-family:arial;
-   font-size:12px;
-/*    text-decoration:underline; */
-}
+  float: right;
+  position: fixed;
+  width: 500px;
+  top: 1ex;
+  right: 45%;
+  text-align: right;
+  color: blue;
+  font-weight: normal;
+  font-family: arial;
+  font-size: 12px; }
 
 span.vbar {
-   height:1.5ex;
-   border-left:1px solid black;
-   width:1px;
-}
+  height: 1.5ex;
+  border-left: 1px solid black;
+  width: 1px; }
 
-div.top_control_bar a {
-   color: #0000BB;
-   text-decoration: none;
-   padding:5px;
-}
-
-div.top_control_bar a:hover {
-   cursor:pointer;
-}
-
-div.top_control_bar a.upload_worksheet {
-}
-
-div.top_control_bar a.worksheets_button {
-}
-
-div.top_control_bar a.upload_worksheet:hover {
-}
-
-div.top_control_bar a.restart_sage {
-}
-
-div.top_control_bar a.restart_sage:hover {
-   background-color:#ff0000;
-}
-
-div.top_control_bar  a.restart_sage_in_progress {
-   background-color:#ff0000;
-   text-decoration:blink;
-}
-
-div.top_control_bar  a.interrupt {
-/*   text-decoration: underline;
-   font-family:arial;
-   font-size:12px;
-   font-weight:bold;
-   color:#000000;
-   */
-}
-
-div.top_control_bar a.interrupt:hover {
-   background-color:#bb0000;
-}
-
-div.top_control_bar  a.interrupt_grey {
-   color:#888888;
-}
-
-div.top_control_bar  a.interrupt_in_progress {
-   color:#FFFFFF;
-   background-color:#bb0000;
-   text-decoration:blink;
-}
-
-div.top_control_bar a.help {
-}
-
-div.top_control_bar a.help:hover{
-   cursor:pointer;
-}
-
-a.slide_mode {
-}
-
-a.slide_mode:hover{
-   cursor:pointer;
-}
-
-a.cell_mode {
-}
-
-a.cell_mode:hover{
-   cursor:pointer;
-}
-
-a.slide_arrow {
-}
-
-a.slide_arrow:hover{
-   cursor:pointer;
-}
-
-
-div.top_control_bar  a.history_link {
-}
-
-div.top_control_bar a.history_link:hover {
-}
-
-
-/* links darker! no underlines! */
+a.slide_mode:hover, a.cell_mode:hover, a.slide_arrow:hover {
+  cursor: pointer; }
 
 span.worksheet_control_commands a {
-   color: #0000BB;
-   text-decoration: none;
-   padding:5px;
-}
-
+  color: #0000BB;
+  text-decoration: none;
+  padding: 5px; }
 span.worksheet_control_commands a:hover {
-   cursor:pointer;
-}
-
-span.worksheet_control_commands  a.plain_text {
-}
-
-span.worksheet_control_commands a.plain_text:hover {
-}
-
-span.worksheet_control_commands  a.doctest_text {
-}
-
-span.worksheet_control_commands a.doctest_text:hover {
-}
-
-span.worksheet_control_commands  a.download_sws {
-}
-
-span.worksheet_control_commands a.download_sws:hover {
-}
-
-span.worksheet_control_commands a.evaluate {
-}
-
-span.worksheet_control_commands a.evaluate:hover {
-}
-
-span.worksheet_control_commands  a.hide{
-}
-
-span.worksheet_control_commands a.hide:hover {
-}
-
-
-
-
+  cursor: pointer; }
 
 div.slideshow_control {
-  float:right;
-}
-
+  float: right; }
 div.slideshow_control:hover {
-   cursor:pointer;
-}
-
-
+  cursor: pointer; }
 div.slideshow_progress {
-  float:right;
-  background-color:white;
-  padding:1px;
-  border:1px solid {{ color2 }};
-  width:20%;
-}
-div.slideshow_progress_bar{
-  z-index:1;
-  position:relative;
-  background-color: {{ color1 }};
-}
+  float: right;
+  background-color: white;
+  padding: 1px;
+  border: 1px solid #cccccc;
+  width: 20%; }
+div.slideshow_progress_bar {
+  z-index: 1;
+  position: relative;
+  background-color: #dcdcdc; }
 div.slideshow_progress_bar:hover {
-   cursor:pointer;
-}
-div.slideshow_progress_text{
-  position:absolute;
-  z-index:2;
-  top:2px;
-  text-align:center;
-  color:black;
-  width:20%;
-}
-
-/************** Introspection ****************/
+  cursor: pointer; }
+div.slideshow_progress_text {
+  position: absolute;
+  z-index: 2;
+  top: 2px;
+  text-align: center;
+  color: black;
+  width: 20%; }
 
 .completion_menu_selected {
-  background-color: #8888ff;
-}
-
-div.introspection {
-}
+  background-color: #8888ff; }
 
 div.docstring {
-  font-family:arial;
+  font-family: arial;
   background-color: #fafafa;
   color: black;
   border: solid 1px black;
-  padding:8px;
-  margin:8px;
-}
+  padding: 8px;
+  margin: 8px; }
 
 pre.literal-block {
   background-color: #ffffff;
   color: black;
   padding: 0 0 0 5px;
-  border-left: 2px solid #c0c0c0;
-}
-
+  border-left: 2px solid #c0c0c0; }
 pre.introspection {
   font-family: monospace;
-  font-size:15px;
+  font-size: 15px;
   background-color: #f1f1f1;
   color: blue;
   border: solid 1px black;
-  padding:8px;
-  margin:8px;
-}
-
+  padding: 8px;
+  margin: 8px; }
 
 ul.completion_menu_one {
   list-style: none;
@@ -312,1435 +224,1114 @@
   z-index: 2;
   background-color: #efefef;
   border: solid 1px black;
-  display:inline;
+  display: inline;
   margin: 5px;
   font-family: monospace;
-  font-size:15px;
-  padding:5px;
-}
+  font-size: 15px;
+  padding: 5px; }
+
 li.completion_menu_one {
-  display:inline;
+  display: inline;
   position: relative;
-  float:left;
-  margin: 0px;
-}
+  float: left;
+  margin: 0px; }
 
 ul.completion_menu_two {
-  display:inline;
+  display: inline;
   position: relative;
   list-style: none;
-  margin: 0px;
-}
+  margin: 0px; }
 
-li.completion_menu_two{
-  display:block;
-  position:relative;
+li.completion_menu_two {
+  display: block;
+  position: relative;
   margin: 3px;
   padding-left: 3px;
-  padding-right: 3px;
-}
-
-li.completion_menu_two:hover{
-   background-color: #8888bb;
-   cursor:pointer;
-}   
-
-
-/***** SEARCH / HELP AREA *********************************/
+  padding-right: 3px; }
+li.completion_menu_two:hover {
+  background-color: #8888bb;
+  cursor: pointer; }
 
 span.search_doc_topbar {
-   z-index: 12;
-   height: 24px;
-   font-family:monospace;
-   font-size: 12px;
-   width:158px;
-   top: 40px;
-   left: 5px;
-   position: fixed;
-   border:1px solid #387CAF;
-   background-color: #73a6ff;
-}
+  z-index: 12;
+  height: 24px;
+  font-family: monospace;
+  font-size: 12px;
+  width: 158px;
+  top: 40px;
+  left: 5px;
+  position: fixed;
+  border: 1px solid #387CAF;
+  background-color: #73a6ff; }
 
-td.menubar{
-   text-decoration: none;
-   font-family:arial;
-   font-size:15px;
-   font-weight:bold;
-   color:#FFFFFF;
-}
+td.menubar {
+  text-decoration: none;
+  font-family: arial;
+  font-size: 15px;
+  font-weight: bold;
+  color: #FFFFFF; }
 
-a.menubar{
-   text-decoration: none;
-   font-family:arial;
-   font-size:15px;
-   font-weight:bold;
-   color:#FFFFFF;
-   background-color:#73a6ff;
-}
+a.menubar {
+  text-decoration: none;
+  font-family: arial;
+  font-size: 15px;
+  font-weight: bold;
+  color: #FFFFFF;
+  background-color: #73a6ff; }
 
 input.search_input {
-   position: fixed;   
-   left: 5px;
-   top: 65px;
-   height: 32px;
-   width: 160px;
-   padding: 4px;
-   z-index: 12;
-   font-family:monospace;
-   font-size:14px;
-   color: #222222;
-   color: #808080;
-   border: 3px solid #387CAF;
-   background: #FFF;
-}
+  position: fixed;
+  left: 5px;
+  top: 65px;
+  height: 32px;
+  width: 160px;
+  padding: 4px;
+  z-index: 12;
+  font-family: monospace;
+  font-size: 14px;
+  color: #222222;
+  color: #808080;
+  border: 3px solid #387CAF;
+  background: #FFF; }
 
 span.search_doc {
-   z-index: 12;
-   font-family:arial;
-   font-size:12px;
-   overflow:auto;
-   position: fixed;
-   top: 96px;
-   left: 5px;
-   width: 154px;
-   height: 150px;
-   margin: 0px;
-   border:1px solid #387CAF;   
-   background-color: white;
-   padding: 2px;   
-}
-
-
-/************ INFO PANES **************************/
-
+  z-index: 12;
+  font-family: arial;
+  font-size: 12px;
+  overflow: auto;
+  position: fixed;
+  top: 96px;
+  left: 5px;
+  width: 154px;
+  height: 150px;
+  margin: 0px;
+  border: 1px solid #387CAF;
+  background-color: white;
+  padding: 2px; }
 span.pane {
-   z-index:30;
-   font-family: monospace;
-   font-size:12px;
-   position: fixed;
-   left: 5px;
-   top: 33px;
-   width: 180px;
-   height:100%;
-   margin: 0px;
-   padding-right: 2px;
-   padding-left: 0px;
-   padding-top: 0px;
-   bottom: 0ex;
-}
-
+  z-index: 30;
+  font-family: monospace;
+  font-size: 12px;
+  position: fixed;
+  left: 5px;
+  top: 33px;
+  width: 180px;
+  height: 100%;
+  margin: 0px;
+  padding-right: 2px;
+  padding-left: 0px;
+  padding-top: 0px;
+  bottom: 0ex; }
 span.plusminus {
-  color:black;
-  font-size:8pt;
-  font-family:monospace;
-}
+  color: black;
+  font-size: 8pt;
+  font-family: monospace; }
 span.plusminus:hover {
-    cursor:pointer;
-}
-
+  cursor: pointer; }
 span.controltoggle {
-  color:#0000ff;
-  font-size:10pt;
-  text-decoration:underline; 
-}
+  color: #0000ff;
+  font-size: 10pt;
+  text-decoration: underline; }
 span.controltoggle:hover {
-    cursor:pointer;
-}
+  cursor: pointer; }
 
 div.left_pane_bar {
-  position:fixed;
-  left: 0px; 
-  top:36px;
+  position: fixed;
+  left: 0px;
+  top: 36px;
   background-color: white;
-  width:8px;
-  height:100%;
-  z-index:100;
-}
+  width: 8px;
+  height: 100%;
+  z-index: 100; }
 div.left_pane_bar:hover {
-  background-color: #8888fe;  /* #000000; */
-}
-
-
-/************ VARIABLES **************************/
+  background-color: #8888fe; }
 
 span.pane div.variables_topbar {
-   color:black;
-   background: url('corner.png') no-repeat top left;
-   background-color: {{ color1 }};
-   font-family:arial;
-   text-decoration: none;
-   font-size:13px;
-   height: 2ex;
-   padding-left: 10px;
-   padding-bottom:1px;
-   width: 174px;
-}
-
+  color: black;
+  background: url('corner.png') no-repeat top left;
+  background-color: #dcdcdc;
+  font-family: arial;
+  text-decoration: none;
+  font-size: 13px;
+  height: 2ex;
+  padding-left: 10px;
+  padding-bottom: 1px;
+  width: 174px; }
 span.pane div.variable_list {
-   font-size:11px;   
-   top:0ex;
-   height:20ex;
-   border:2px solid {{ color1 }};
-   width: 180px;
-   overflow:auto;
-}
+  font-size: 11px;
+  top: 0ex;
+  height: 20ex;
+  border: 2px solid #cccccc;
+  width: 180px;
+  overflow: auto; }
 
 div.variable_name {
-   padding-left:1ex;
-   border-top:1px solid #d3e9ff;
-}
-
-/*div.variable_name:hover {
-   background-color:{{ color1 }};
-   cursor:pointer;   
-}*/
-
-span.varname {
-}
+  padding-left: 1ex;
+  border-top: 1px solid #d3e9ff; }
 
 span.vartype {
-  /* color:#888888; */
-  color:#657d6c;
-}
-
-/************ ATTACHED **************************/
-
+  color: #657d6c; }
 span.pane div.attached_topbar {
-   color: black;
-   height: 2ex;
-   top: 0ex;
-   background: url('corner.png') no-repeat top left;
-   background-color: {{ color1 }};
-   text-decoration: none;
-   font-size:13px;
-   font-family:arial;
-   padding-left: 10px;
-   padding-bottom:1px;
-   width: 174px;
-}
-
+  color: black;
+  height: 2ex;
+  top: 0ex;
+  background: url('corner.png') no-repeat top left;
+  background-color: #dcdcdc;
+  text-decoration: none;
+  font-size: 13px;
+  font-family: arial;
+  padding-left: 10px;
+  padding-bottom: 1px;
+  width: 174px; }
 span.pane div.attached_list {
-   font-size:11px;
-   top:0ex;
-   height:20ex;
-   border:2px solid  {{ color1 }};
-   width: 180px;
-   overflow:auto;
-}
+  font-size: 11px;
+  top: 0ex;
+  height: 20ex;
+  border: 2px solid #dcdcdc;
+  width: 180px;
+  overflow: auto; }
 
 div.attached_filename {
-   padding-left:1ex;
-   border-top:1px solid #d3e9ff;
-}
-/*
-div.attached_filename:hover {
-   background-color:{{ color1 }};
-   cursor:pointer;   
-}
-*/
-
-/************ WORKSHEETS **************************/
+  padding-left: 1ex;
+  border-top: 1px solid #d3e9ff; }
 
 span.pane div.worksheets_topbar {
-   color:black;
-   height: 3ex;
-   top: 0ex;
-   background: url('/images/corner.png') no-repeat top left;
-   background-color: {{ color2 }};
-   text-decoration: none;
-   font-size:15px;
-   font-family:arial;
-   padding-left: 10px;
-   padding-top:10px;
-   width: 174px;
-}
+  color: black;
+  height: 3ex;
+  top: 0ex;
+  background: url('/images/corner.png') no-repeat top left;
+  background-color: #cccccc;
+  text-decoration: none;
+  font-size: 15px;
+  font-family: arial;
+  padding-left: 10px;
+  padding-top: 10px;
+  width: 174px; }
 
 a.left_panel_hide {
-   position: relative;
-   top:0px; 
-   right:-1px;
-   text-align:right;
-   color:blue;   
-   font-weight:normal;   
-   font-family:arial;
-   font-size:12px;
-}
-
+  position: relative;
+  top: 0px;
+  right: -1px;
+  text-align: right;
+  color: blue;
+  font-weight: normal;
+  font-family: arial;
+  font-size: 12px; }
 a.left_panel_hide:hover {
-   cursor:pointer;
-}
+  cursor: pointer; }
 
 span.X {
-   color:white;
-   font-family:arial, monospace;
-   font-weight:bold;
-   cursor:pointer;    
-}
-
+  color: white;
+  font-family: arial, monospace;
+  font-weight: bold;
+  cursor: pointer; }
 span.pane div.add_new_worksheet_menu {
-   position:relative;
-   color:black;
-   padding-top: 0.5ex;
-   padding-bottom: 0.5ex;
-   left: 0ex;
-   background-color: white;
-   text-decoration: none;
-   font-size:11px;
-   font-family:arial;
-   padding-left: 0px;
-   width: 174px;
-}
+  position: relative;
+  color: black;
+  padding-top: 0.5ex;
+  padding-bottom: 0.5ex;
+  left: 0ex;
+  background-color: white;
+  text-decoration: none;
+  font-size: 11px;
+  font-family: arial;
+  padding-left: 0px;
+  width: 174px; }
 
 input.add_new_worksheet_menu {
-   width:100%
-}
+  width: 100%; }
 
 button.add_new_worksheet_menu {
-   font-size:14px;
-   font-family:sans-serif;
-}
+  font-size: 14px;
+  font-family: sans-serif; }
 
 span.pane div.upload_worksheet_menu {
-   color:black;
-   top: 0ex;
-   background-color: {{ color2 }};
-   text-decoration: none;
-   font-size:11px;
-   font-family:arial;
-   padding-left: 10px;
-   width: 174px;
-   display:none; 
-}
+  color: black;
+  top: 0ex;
+  background-color: #cccccc;
+  text-decoration: none;
+  font-size: 11px;
+  font-family: arial;
+  padding-left: 10px;
+  width: 174px;
+  display: none; }
 
 button.upload_worksheet_menu {
-   font-size:11px;
-   font-family:arial;
-}
+  font-size: 11px;
+  font-family: arial; }
 
-input.upload_worksheet_menu {
-
-}
 
 span.pane div.delete_worksheet_menu {
-   color:black;
-   top: 0ex;
-   background-color: {{ color2 }};
-   text-decoration: none;
-   font-size:11px;
-   font-family:arial;
-   padding-left: 10px;
-   width: 174px;
-   display:none; 
-}
+  color: black;
+  top: 0ex;
+  background-color: #cccccc;
+  text-decoration: none;
+  font-size: 11px;
+  font-family: arial;
+  padding-left: 10px;
+  width: 174px;
+  display: none; }
 
 input.delete_worksheet_menu {
-   width:50%
-}
+  width: 50%; }
 
 button.delete_worksheet_menu {
-   font-size:11px;
-   font-family:arial;
-   background-color: #ffcccc;
-}
-
-span.pane div.worksheet_list {
-   position:fixed; 
-   overflow:scroll;
-   font-size:12px;
-   top:25ex;
-   bottom:2ex;
-   left:1ex;
-   border:2px solid {{ color2 }};
-   width: 180px;
-}
+  font-size: 11px;
+  font-family: arial;
+  background-color: #ffcccc; }
 
 a.new_worksheet {
-   font-family: arial, monospace;
-   font-size:12pt;
-   text-align:right;
-   color: #0000aa
-}
-
+  font-family: arial, monospace;
+  font-size: 12pt;
+  text-align: right;
+  color: #0000aa; }
 a.new_worksheet:hover {
-  cursor:pointer;
-}
+  cursor: pointer; }
 
 div.worksheet_bottom_padding {
-   height:50%;
-}
-
+  height: 50%; }
 div.worksheet_top_padding {
-   height:5%;
-}
-
+  height: 5%; }
 div.worksheet_menu {
-   top:50px;
-}
-
-a.worksheet_title {
-   text-decoration:none;
-   font-size:20px;
-   font-family:arial;
-   font-weight:bold;
-   color:#000000;
-}
-
-a.worksheet_title:hover {
-   background-color:#ffffcc;
-   cursor:pointer;
-}
-
-div.worksheet_title {
-   padding-left: 1em;
-   background-color: #ffffff;
-   color:black;
-}
-
+  top: 50px; }
 
 div.worksheet_print_title {
-   text-decoration:none;
-   font-size:24px;
-   font-family:arial;
-   font-weight:bold;
-   color:#000000;
-   text-align:center;
-}
-
+  text-decoration: none;
+  font-size: 24px;
+  font-family: arial;
+  font-weight: bold;
+  color: #000000;
+  text-align: center; }
 div.worksheet_title_under {
-   z-index:0;
-   padding-top: 3px;
-   padding-left: 1em;
-   background-color: {{ color1 }};
-   /*width: 100%;*/
-   font-family:arial;
-   font-size: 22px;
-   font-weight:bold;
-   color:black;
-}
-
+  z-index: 0;
+  padding-top: 3px;
+  padding-left: 1em;
+  background-color: #dcdcdc;
+  font-family: arial;
+  font-size: 22px;
+  font-weight: bold;
+  color: black; }
 div.worksheet_cell_list {
-   padding-left:0.5ex;
-}
+  padding-left: 0.5ex; }
 
 a.delete_worksheet {
-   font-family: arial, monospace;
-   font-size:8pt;
-   text-decoration:underline;
-   text-align:right;
-   color: #0000aa
-}
-
+  font-family: arial, monospace;
+  font-size: 8pt;
+  text-decoration: underline;
+  text-align: right;
+  color: #0000aa; }
 a.delete_worksheet:hover {
-  cursor:pointer;
-}
-
-
+  cursor: pointer; }
 a.upload_worksheet:hover {
-  cursor:pointer;
-}
+  cursor: pointer; }
 
 span.pane a.worksheet_current {
-   font-size:14px;
-   padding-left:1ex;
-   background-color:{{ color2 }};
-   text-decoration:none;
-   color:black;
- }
+  font-size: 14px;
+  padding-left: 1ex;
+  background-color: #cccccc;
+  text-decoration: none;
+  color: black; }
+span.pane a.worksheet_current_computing {
+  font-size: 14px;
+  padding-left: 1ex;
+  background-color: #ffd1d1;
+  text-decoration: none;
+  color: black; }
+span.pane a.worksheet_other {
+  font-size: 14px;
+  padding-left: 1ex;
+  background-color: white;
+  text-decoration: none;
+  color: black; }
+span.pane a.worksheet_other:hover {
+  background-color: #cccccc;
+  text-decoration: none;
+  cursor: pointer; }
+span.pane a.worksheet_other_computing {
+  font-size: 14px;
+  padding-left: 1ex;
+  background-color: #ffd1d1;
+  text-decoration: none;
+  color: black; }
 
-span.pane a.worksheet_current_computing {
-   font-size:14px;
-   padding-left:1ex;
-   background-color:#ffd1d1;
-   text-decoration:none;
-   color:black;
- }
+/* ***************** Doc-Browser *************** */
+.verbatim {
+  background-color: #fafad2;
+  border-style: solid;
+  border-width: 1px 1px;
+  border-color: black; }
 
-span.pane a.worksheet_other {
-   font-size:14px;
-   padding-left:1ex;
-   background-color:white;
-   text-decoration:none;
-   color:black;
-}
-
-span.pane a.worksheet_other:hover {
-   background-color:{{ color2 }};
-   text-decoration:none;
-   cursor:pointer;   
-}
-
-span.pane a.worksheet_other_computing {
-   font-size:14px;
-   padding-left:1ex;
-   background-color:#ffd1d1;
-   text-decoration:none;
-   color:black;
-}
-
-/*********** DOC-BROWSER************************/
-
-
-.verbatim {
-    background-color: #fafad2;
-    border-style: solid;
-    border-width: 1px 1px;
-    border-color: black;
-}
-
-
-/************ OBJECTS **************************/
-
+/* **************** Objects ******************** */
 span.pane div.objects_topbar {
-   color:black;
-   height: 2ex;
-   top: 0ex;
-   background: url('corner.png') no-repeat top left;
-   background-color: {{ color2 }};
-   text-decoration: none;
-   font-size:13px;
-   font-family:arial;
-   padding-left: 10px;
-   padding-bottom:1px;
-   width: 174px;
-}
-
+  color: black;
+  height: 2ex;
+  top: 0ex;
+  background: url('corner.png') no-repeat top left;
+  background-color: #cccccc;
+  text-decoration: none;
+  font-size: 13px;
+  font-family: arial;
+  padding-left: 10px;
+  padding-bottom: 1px;
+  width: 174px; }
 span.pane div.object_list {
-   font-size:11px;
-   height:20ex;
-   border:2px solid {{ color2 }};
-   width: 180px;
-   overflow:auto;
-}
+  font-size: 11px;
+  height: 20ex;
+  border: 2px solid #cccccc;
+  width: 180px;
+  overflow: auto; }
 
 a.object_name {
-   padding-left:1ex;
-   border-top:1px solid {{ color2 }};   
-   background-color:white;
-   text-decoration:none;
-   color:black;
-}
+  padding-left: 1ex;
+  border-top: 1px solid #cccccc;
+  background-color: white;
+  text-decoration: none;
+  color: black; }
+a.object_name:hover {
+  background-color: #cccccc;
+  text-decoration: none;
+  color: black;
+  cursor: pointer; }
 
-a.object_name:hover {
-   background-color:{{ color2 }};
-   text-decoration:none;
-   color:black;
-   cursor:pointer;   
-}
-
-
-
-/************ CONTROLS **************************/
-
-div.control_area{
-    vertical-align: top;
-}
+/* ******************** Controls ******************** */
+div.control_area {
+  vertical-align: top; }
 
 span.control {
-    border:1px solid white;
-    font-family: monospace;
-    font-size:14pt;
-    font-weight:bold;
-}
+  border: 1px solid white;
+  font-family: monospace;
+  font-size: 14pt;
+  font-weight: bold; }
+span.control a.cs {
+  color: #777777;
+  text-decoration: none;
+  border: 0px solid white; }
+span.control:hover a.cs, span.control a:hover.cs {
+  color: black;
+  border: 1px solid #333333; }
 
-span.control a.cs {
-    color:#777777;
-    text-decoration:none;
-    border:0px solid white;
-}
-
-span.control:hover a.cs, span.control a:hover.cs {
-    color:black;
-    border:1px solid #333333;
-}
-
-/************ WORKSHEET **************************/
-
+/* *************** Worksheet ********************* */
 div.worksheet {
   background-color: white;
-  border:1px solid #aaa;
-}
-
-
-div.banner{
-  background-color:white;
-  font-family: sans-serif; 
-  font-size:18px;
-  text-decoration: none;
-  color: #1950c8;
-}
-
-div.banner a.banner{
-    text-decoration:none;
-    border:none;
-    margin-top:2px;
-}
-
-a.banner:visited {
-  color: #1950c8;
-}
-
-div.banner a.banner img{
-    text-decoration:none;
-    border:none;
-    margin-top:2px;
-}
-
-div.banner a.banner:hover {
-}
+  border: 1px solid #aaa; }
 
 input.btn {
   font-family: monospace;
-  font-size:13pt;
-  font-weight:bold;
-  color:#808080;
-  text-decoration:none;
+  font-size: 13pt;
+  font-weight: bold;
+  color: #808080;
+  text-decoration: none;
   background: white;
-  padding:0px;
-  margin:0px;
-  border:1px solid white;
-}
+  padding: 0px;
+  margin: 0px;
+  border: 1px solid white; }
 input.btn:hover {
   color: black;
   text-decoration: none;
   background: white;
   padding: 0px;
   margin: 0px;
-  border: 1px solid #333333;
-}
+  border: 1px solid #333333; }
 
-/************ CELL INPUT **************************/
-
+/* *************** Cell Input ***************** */
 div.cell_visible {
-    display:block;
-}
-
+  display: block; }
 div.cell_evaluated {
-    border-left: 1px solid white;
-    padding-left:3px;
-}
-
+  border-left: 1px solid white;
+  padding-left: 3px; }
 div.cell_not_evaluated {
-    border-left: 1px solid #ff8888;
-    padding-left:3px;    
-}
+  border-left: 1px solid #ff8888;
+  padding-left: 3px; }
 
 td.cell_number {
-   font-size:12pt;
-   font-family:arial, monospace;
-   color:#bbbbbb;
-   text-align:left;
-   border-left:4px solid #ffffff;
-}
-
+  font-size: 12pt;
+  font-family: arial, monospace;
+  color: #bbbbbb;
+  text-align: left;
+  border-left: 4px solid #ffffff; }
 td.cell_number:hover {
-   color:#555555;
-   cursor:pointer;
-}
-
+  color: #555555;
+  cursor: pointer; }
 td.cell_number_running {
-   font-size:12pt;
-   font-family:arial, monospace;
-   color:#bbbbbb;
-   border-left:4px solid #aaffaa;
-   /* background-color: #eeeeee; */
-   text-align:left;
-}
-
+  font-size: 12pt;
+  font-family: arial, monospace;
+  color: #bbbbbb;
+  border-left: 4px solid #aaffaa;
+  text-align: left; }
 td.cell_number_running:hover {
-  cursor:wait;
-}
-
-td.output_cell {
-   /* width: 100% */ 
-   /* height:3px; */
-}
+  cursor: wait; }
 
 div.cellbox {
-  z-index:2;
+  z-index: 2;
   background-color: white;
   padding-left: .5em;
-  padding-top: 4em;
-}
-
+  padding-top: 4em; }
 
 textarea.cell_input {
-  color:#000000;
+  color: #000000;
   background-color: white;
   border-left: 1px solid  #a8a8a8;
   border-bottom: 1px solid  #a8a8a8;
   border-top: 1px solid  #a8a8a8;
-  border-right: 1px solid  #a8a8a8;   
+  border-right: 1px solid  #a8a8a8;
   font-family: monospace;
-  font-size:12pt;
-  overflow:hidden;
-  padding-left:5px;
-  padding-top:3px;
-  padding-bottom:0px;
-  width: 97%; 
-  margin-bottom:0px;
-  margin-top:0px;
-  line-height:1.2em;  
-}
+  font-size: 12pt;
+  overflow: hidden;
+  padding-left: 5px;
+  padding-top: 3px;
+  padding-bottom: 0px;
+  width: 97%;
+  margin-bottom: 0px;
+  margin-top: 0px;
+  line-height: 1.2em; }
 
 pre.cell_input {
-  color:#000000;
+  color: #000000;
   background-color: white;
   border-left: 1px solid  #a8a8a8;
   border-bottom: 1px solid  #a8a8a8;
   border-top: 1px solid  #a8a8a8;
-  border-right: 1px solid  #a8a8a8; 
+  border-right: 1px solid  #a8a8a8;
   font-family: monospace;
-  font-size:12pt;
-  padding-left:5px;
-  padding-top:3px;
-  padding-bottom:0px;
+  font-size: 12pt;
+  padding-left: 5px;
+  padding-top: 3px;
+  padding-bottom: 0px;
   width: 100%;
-  margin-bottom:0px;
-  margin-top:0px;
-
-}
+  margin-bottom: 0px;
+  margin-top: 0px; }
 pre.cell_input:hover {
-  cursor:text;
-}
+  cursor: text; }
 
 textarea.cell_input_hide {
   background-color: white;
   border: 0px solid white;
   font-family: monospace;
-  font-size:12pt;
-  color:#888888;
-  overflow:hidden;
-  padding-left:3px;
-  padding-top:0px;
-  padding-bottom:0px;
-  /* width: 100%; */
-  height:1em; 
-  margin:0px;
-}
-
+  font-size: 12pt;
+  color: #888888;
+  overflow: hidden;
+  padding-left: 3px;
+  padding-top: 0px;
+  padding-bottom: 0px;
+  height: 1em;
+  margin: 0px; }
 
 pre.cell_input_hide {
   background-color: white;
   border: 2px solid #e8e8e8;
   font-family: monospace;
-  font-size:12pt;
-  overflow:hidden;
-  padding-left:3px;
-  padding-top:0px;
-  padding-bottom:0px;
-  /* width: 100%; */
-  height:1em; 
-  margin:0px;
-}
-
+  font-size: 12pt;
+  overflow: hidden;
+  padding-left: 3px;
+  padding-top: 0px;
+  padding-bottom: 0px;
+  height: 1em;
+  margin: 0px; }
 pre.cell_input_hide:hover {
-  cursor:text;
-}
+  cursor: text; }
 
 textarea.cell_input_active {
   background-color: white;
   border-left: 2px solid  #8888fe;
   border-bottom: 2px solid  #8888fe;
-  border-top: 2px solid  #8888fe;    
-  border-right: 2px solid  #8888fe;    
+  border-top: 2px solid  #8888fe;
+  border-right: 2px solid  #8888fe;
   font-family: monospace;
-  font-size:12pt;
-  overflow:hidden;
-  padding-left:5px;
-  padding-top:3px;
-  padding-bottom:0px;
-  margin-top:0px;
-  margin-bottom:0px;
-  line-height:1.2em;  
-  width: 97%;
-}
+  font-size: 12pt;
+  overflow: hidden;
+  padding-left: 5px;
+  padding-top: 3px;
+  padding-bottom: 0px;
+  margin-top: 0px;
+  margin-bottom: 0px;
+  line-height: 1.2em;
+  width: 97%; }
 
-/* used for resize only */
 div.cell_input_active {
   background-color: white;
   border-left: 2px solid  #ff0000;
   border-bottom: 2px solid  #ff0000;
   border-top: 2px solid  #ff0000;
-  border-right: 2px solid  #8888fe;    
+  border-right: 2px solid  #8888fe;
   font-family: monospace;
-  font-size:12pt;
-  padding-left:5px;
-  padding-top:3px;
-  padding-bottom:0px;
-  margin-top:0px;
-  margin-bottom:0px;
-  line-height:1.2em;  
+  font-size: 12pt;
+  padding-left: 5px;
+  padding-top: 3px;
+  padding-bottom: 0px;
+  margin-top: 0px;
+  margin-bottom: 0px;
+  line-height: 1.2em;
   width: 97%;
   z-index: -100;
   visibility: hidden;
-  position: absolute;
-}
-
-/* used for printing */
+  position: absolute; }
 div.cell_input_print {
   background-color: white;
   border-left: 1px solid  #a8a8a8;
   border-bottom: 1px solid  #a8a8a8;
   border-top: 1px solid  #a8a8a8;
-  border-right: 1px solid  #a8a8a8; 
+  border-right: 1px solid  #a8a8a8;
   font-family: monospace;
-  font-size:12pt;
-  padding-left:5px;
-  padding-top:3px;
-  padding-bottom:0px;
-  margin-top:0px;
-  margin-bottom:0px;
-  line-height:1.2em;  
-  width: 97%;
-}
+  font-size: 12pt;
+  padding-left: 5px;
+  padding-top: 3px;
+  padding-bottom: 0px;
+  margin-top: 0px;
+  margin-bottom: 0px;
+  line-height: 1.2em;
+  width: 97%; }
 
-textarea.cell_input:hover{
-  cursor:text;
-}
+textarea.cell_input:hover {
+  cursor: text; }
 
 a.eval_button {
-  display:none;
-}
+  display: none; }
 a.eval_button_active {
   display: block;
   position: relative;
   top: 2px;
-  margin:0px;
-  padding:0px;
-  font-size:10pt;
-}
+  margin: 0px;
+  padding: 0px;
+  font-size: 10pt; }
 
-
-/************ CELL OUTPUT **************************/
-
+/* *************** Cell Output *********************** */
 div.cell_div_output {
   font-family: monospace;
-  font-size:12pt;
-  /*width: 95%;*/
-  margin-top:-5px;
-  margin-bottom:5px;
-  padding-bottom:5px;  
-  
- /* border-left: 1px solid #aaaaff;  */
-}
-
+  font-size: 12pt;
+  margin-top: -5px;
+  margin-bottom: 5px;
+  padding-bottom: 5px; }
 div.cell_output_div {
-  overflow-x: auto;
-}
+  overflow-x: auto; }
 
 table.cell_output_box {
-  margin:0px;
-  padding:0px;    
-}
-
+  margin: 0px;
+  padding: 0px; }
 table.table_form * td {
   padding-top: 5px;
   padding-bottom: 5px;
   padding-left: 15px;
+  padding-right: 15px; }
+table.table_form * th {
+  background: #a6ba4e;
+  height: 29px;
+  padding-left: 15px;
   padding-right: 15px;
-}
-
-table.table_form * th {
-    background: #a6ba4e;
-    height: 29px;
-    padding-left: 15px;
-    padding-right: 15px;
-    padding-top: 5px;
-    padding-bottom: 5px;
-    color: #FFF;
-    text-align: left;
-}
-
-
+  padding-top: 5px;
+  padding-bottom: 5px;
+  color: #FFF;
+  text-align: left; }
 table.table_form * tr.row-a {
   background: #F8F8F8;
-  text-align: left;
-}
-
+  text-align: left; }
 table.table_form * tr.row-b {
   background: #EFEFEF;
-  text-align: left;
-}
-
-/*table.cell_output_box:hover {
-  background-color: #fafafa; 
-}
-*/
+  text-align: left; }
 
 div.cell_div_output_wrap {
-  font-size:12pt;
-  margin:0px;
-  padding-left:0px;  
-  color:#0000aa;
-}
-
+  font-size: 12pt;
+  margin: 0px;
+  padding-left: 0px;
+  color: #0000aa; }
 div.cell_output_wrap pre.cell_output_print_wrap {
-  font-size:12pt;
-  margin:0px;
-  padding:0px;  
-  color:#0000aa;
-}
-
+  font-size: 12pt;
+  margin: 0px;
+  padding: 0px;
+  color: #0000aa; }
 div.cell_output_print_wrap {
-   font-size:10pt;
-}
-
-div.cell_output_nowrap {
-  display:none;
-}
-div.cell_output_print_nowrap {
-  display:none;
-}
-
-div.cell_output_hidden {
-  display:none;
-}
-
-
-div.cell_output_nowrap_wrap {
- display:none;
-}
-div.cell_output_print_nowrap_wrap {
- display:none;
-}
+  font-size: 10pt; }
+div.cell_output_nowrap, div.cell_output_print_nowrap, div.cell_output_hidden, div.cell_output_nowrap_wrap, div.cell_output_print_nowrap_wrap {
+  display: none; }
 div.cell_output_nowrap_nowrap {
-  font-size:12pt;
-  margin:0px;
-  padding:0px;
-  color:#0000aa;
-}
+  font-size: 12pt;
+  margin: 0px;
+  padding: 0px;
+  color: #0000aa; }
 div.cell_output_nowrap_hidden {
-  display:none;
-}
-
-div.cell_output_html_wrap {
+  display: none; }
+div.cell_output_html_wrap, div.cell_output_html_nowrap {
   font-family: monospace;
-  font-size:12pt;
-}
-div.cell_output_html_nowrap {
-  font-family: monospace;
-  font-size:12pt;
-}
+  font-size: 12pt; }
 div.cell_output_html_hidden {
-   display:none;
-}
-
+  display: none; }
 div.cell_div_output_running {
   font-family: monospace;
-  font-size:12pt;
-  /* width: 100%; */
-  margin:0px;
-  background-color:#ffffff;
-  padding:0px;  
-}
-
+  font-size: 12pt;
+  margin: 0px;
+  background-color: #ffffff;
+  padding: 0px; }
 div.cell_div_output_running:hover {
-  cursor:wait;
-}
-
-
+  cursor: wait; }
 div.cell_div_output_hidden {
   width: 100%;
   height: 3px;
-  margin:0px;
-  border-left: 4em solid #aaaaaa; 
-/*   border-top: 1px solid {{ color1 }};
-  border-bottom: 1px solid {{ color1 }};
-  */
-}
+  margin: 0px;
+  border-left: 4em solid #aaaaaa; }
 
 pre.shrunk {
-  font-size:12pt;
-  margin:0px;
-}
-
-pre.cell_output_hidden {
-  display: none;
-}
-
-pre.cell_output_hide {
-  display:none;
-}
+  font-size: 12pt;
+  margin: 0px; }
+pre.cell_output_hidden, pre.cell_output_hide {
+  display: none; }
 
 a.file_link {
-  text-decoration:underline;
-}
+  text-decoration: underline; }
 
+/* ************ Inserting new cells ****************** */
+div.insert_new_cell {
+  height: 6px;
+  display: block;
+  margin: 3px; }
+div.insert_new_cell:hover {
+  background-color: #8888fe;
+  margin: 3px; }
 
-/************ INSERTING NEW CELLS **************************/
-
-div.insert_new_cell {
-  height:6px;
-  /* width:100%; /*
-  /* border-top: 4px solid white; */
-  display:block;  
-  margin:3px;
-}
-
-div.insert_new_cell:hover {
-  /* border-top: 4px solid #000000; */
-  background-color: #8888fe;  /* #000000; */
-  margin:3px;  
-  /* background-color:#eeeeee; */
-}
-
-
-/************ DEBUG WINDOW **************************/
-
+/* ***************** DEBUG WINDOW ******************* */
 div.debug_window_active {
-  background-color: white; 
-  border: 1px solid #fe8888;  
-  overflow:auto; 
-  padding-left:3px;
-  padding-top:0px;
-  padding-bottom:0px;
-  /* width: 100%; */
-}
+  background-color: white;
+  border: 1px solid #fe8888;
+  overflow: auto;
+  padding-left: 3px;
+  padding-top: 0px;
+  padding-bottom: 0px; }
 div.debug_window_inactive {
-  background-color: white; 
-  border: 1px solid #888888;  
-  overflow:auto; 
-  padding-left:0px;
-  padding-top:0px;
-  padding-bottom:0px;
-  /* width: 100%; */
-}
-
-
+  background-color: white;
+  border: 1px solid #888888;
+  overflow: auto;
+  padding-left: 0px;
+  padding-top: 0px;
+  padding-bottom: 0px; }
 div.debug_output {
-  background-color: white; 
+  background-color: white;
   border: 0px;
   font-family: monospace;
-  font-size:10pt;
-  overflow:scroll; 
-  padding-left:3px;
-  padding-top:0px;
-  padding-bottom:0px;
-  height: 10em;
-  /* width: 100%; */
-}
-
+  font-size: 10pt;
+  overflow: scroll;
+  padding-left: 3px;
+  padding-top: 0px;
+  padding-bottom: 0px;
+  height: 10em; }
 
 textarea.debug_input {
-  background-color: white; 
-  border: 1px solid #8888fe;  
+  background-color: white;
+  border: 1px solid #8888fe;
   font-family: monospace;
-  font-size:12pt;
-  overflow:scroll; 
-  padding-left:3px;
-  padding-top:0px;
-  padding-bottom:0px;
-  /* width: 100%; */
-}
+  font-size: 12pt;
+  overflow: scroll;
+  padding-left: 3px;
+  padding-top: 0px;
+  padding-bottom: 0px; }
 
-span.red{
-  color:red;
-}
+span.red {
+  color: red; }
 
-/****************** Other **************/
-
-a.worksheetname{
-   text-decoration: none;
-   font-weight: bold; 
-   font-size:14px;
-   color:#222222;
-}
-
-a.worksheetname:visited{
-   color:#222222;
-}
-
-a.worksheetname_moved{
-   color:#888888; 
-   text-decoration: none;
-   font-weight:normal;
-}
+/* ********** Other ************** */
+a.worksheetname {
+  text-decoration: none;
+  font-weight: bold;
+  font-size: 14px;
+  color: #222222; }
+a.worksheetname:visited {
+  color: #222222; }
+a.worksheetname_moved {
+  color: #888888;
+  text-decoration: none;
+  font-weight: normal; }
 
 span.worksheet_buttons {
-    position:relative;
-    top: -20ex;
-    right: 0ex;
-}
+  position: relative;
+  top: -20ex;
+  right: 0ex; }
 
 .flush-right {
-    position:absolute;      /* All browsers */
-    top: auto;              /* Standards  browsers */
-    right: 0;               /* All except IE */
-}
-    
+  position: absolute;
+  top: auto;
+  right: 0; }
+
 .thin-right {
-    position:absolute;      /* All browsers */
-    top: auto;              /* Standards  browsers */
-    right: 0;               /* All except IE */
-    width: 70%;
-}
+  position: absolute;
+  top: auto;
+  right: 0;
+  width: 70%; }
 
-/************ User Home **************************/
-
+/* ***** User Home ********* */
 span.username {
   font-family: sans-serif;
-  font-weight:bold;
-  font-size:14px;
-  padding:1ex;
-}
-
+  font-weight: bold;
+  font-size: 14px;
+  padding: 1ex; }
 span.ratingmsg {
   color: #112abb;
-  padding:0.6ex;
-  font-size:14px;
-}
-
+  padding: 0.6ex;
+  font-size: 14px; }
 span.pubmsg {
   font-family: sans-serif;
   color: #112abb;
-  padding:0.6ex;
-  font-size:12px;
-}
-
-a.usercontrol {
-  color: #112abb;
-  padding:0.6ex;
-  font-size:14px;
-  text-decoration:underline;
-}
-
-a.usercontrol:hover {
-  cursor:pointer;
-}
-
-span.usercontrol {
-  color: #112abb;
-  padding:0.6ex;
-  font-size:14px;
-}
-
+  padding: 0.6ex;
+  font-size: 12px; }
 
 a.boldusercontrol {
   color: #112abb;
-  padding:1ex;
-  font-weight:bold;
-  font-size:14px;
-}
-
+  padding: 1ex;
+  font-weight: bold;
+  font-size: 14px; }
 a.control, a.control-select {
-  background-color:#7799bb;
-  font-family: sans-serif; 
+  background-color: #7799bb;
+  font-family: sans-serif;
   color: #ffffff;
-  padding-top:0.5ex;
-  padding-bottom:0.5ex;
-  padding-left:1ex;
-  padding-right:1ex;
-  font-size:15px;
-  font-weight:bold;
-  text-decoration: none;
-}
-
+  padding-top: 0.5ex;
+  padding-bottom: 0.5ex;
+  padding-left: 1ex;
+  padding-right: 1ex;
+  font-size: 15px;
+  font-weight: bold;
+  text-decoration: none; }
 a.control:hover {
-   cursor:pointer;
-}
-
+  cursor: pointer; }
 a.control-select {
- background-color:#4477aa;
-}
-
+  background-color: #4477aa; }
 a.control-select:hover {
-   cursor:pointer;
-}
+  cursor: pointer; }
 
 span.sharebar {
-  background-color:#4477aa;
-  font-family: sans-serif; 
+  background-color: #4477aa;
+  font-family: sans-serif;
   color: #ffffff;
-  position:absolute;
-  left:1ex;
-  right:0ex;
-  padding-top:1ex;
-  padding-bottom:1ex;
-  padding-left:4ex;
-  font-size:18px;
-  font-weight:bold;
-}
+  position: absolute;
+  left: 1ex;
+  right: 0ex;
+  padding-top: 1ex;
+  padding-bottom: 1ex;
+  padding-left: 4ex;
+  font-size: 18px;
+  font-weight: bold; }
 
 textarea.edit {
-    font-family: courier, monospace;
-    font-size:10pt;
-    border: 1px solid #8cacbb;  
-    color: black;
-    background-color: white;
-    padding: 3px;
-    overflow:auto;
-    /* width: 100%; */
-    margin-top: 0.5em;
-}
+  font-family: courier, monospace;
+  font-size: 10pt;
+  border: 1px solid #8cacbb;
+  color: black;
+  background-color: white;
+  padding: 3px;
+  overflow: auto;
+  margin-top: 0.5em; }
 
 a.listcontrol {
-  padding:1ex;
+  padding: 1ex;
   color: #112abb;
-  font-weight:bold;
-  font-size:14px;
-  text-decoration:none;
-}
-
-hr.usercontrol {
-   border: 0;
-   width: 99%;
-   color: #c9d7f1;
-   background-color: #c9d7f1;
-   height: 1px;   
-}
+  font-weight: bold;
+  font-size: 14px;
+  text-decoration: none; }
 
 hr.greybar hr.negative_greybar {
-   border: 0;
-   width: 99%;
-   color: #aaa;
-   background-color: #aaa;
-   height: 1px;   
-}
-
+  border: 0;
+  width: 99%;
+  color: #aaa;
+  background-color: #aaa;
+  height: 1px; }
 hr.negative_greybar {
-   top:-1em;
-   position:relative;
-}
+  top: -1em;
+  position: relative; }
 
 span.checkcol {
-  position:relative;
-  left:0%;
-  width:10%;
-}
-
+  position: relative;
+  left: 0%;
+  width: 10%; }
 span.leftcol {
-  position:relative;
-  left:10%;
-  width:20%;
-}
-
+  position: relative;
+  left: 10%;
+  width: 20%; }
 span.middlecol {
-  position:relative;
-  left:30%;
-  width:20%;
-}
-
+  position: relative;
+  left: 30%;
+  width: 20%; }
 span.rightcol {
-  position:relative;
-  left:50%;
-  width:20%;
-}
-
-tr.greybox {
-   background-color: #e8eef7;
-}
+  position: relative;
+  left: 50%;
+  width: 20%; }
 
 td.entry {
-   padding:4px;
-}
+  padding: 4px; }
 
 div.thinspace {
-   border: 0;
-   /*width: 100%;*/
-   height: 2px;   
-}
+  border: 0;
+  height: 2px; }
 
 tr.thingreybox {
-   background-color: #aaa;
-}
+  background-color: #aaa; }
 
 div.ultrathinspace {
-   border: 0;
-   /*width: 100%;*/
-   height: 0px;   
-}
+  border: 0;
+  height: 0px; }
 
 span.lastedit {
   font-family: sans-serif;
-  font-size:10px;
-  color: #717171;
-}
-
+  font-size: 10px;
+  color: #717171; }
 span.revs {
   font-family: sans-serif;
-  font-size:12px;
-  font-weight:bold;
-  color: #333333;
-}
-
+  font-size: 12px;
+  font-weight: bold;
+  color: #333333; }
 span.users {
   font-family: sans-serif;
-  font-size:13px;
-  color: #222222;
-}
+  font-size: 13px;
+  color: #222222; }
 
 a.share {
   font-family: sans-serif;
-  font-size:10px;
-  color: #7777cc;
-}
+  font-size: 10px;
+  color: #7777cc; }
 
 select.worksheet {
-  width:6em; 
+  width: 6em;
   border: #aaaaaa;
   border-style: solid;
   border-top-width: 1px;
   border-right-width: 1px;
   border-bottom-width: 1px;
-  border-left-width: 1px
-}
-
-select.worksheet_list {
-  width:5em;
-    border: #aaaaaa;
+  border-left-width: 1px; }
+select.worksheet_edit {
+  width: 5em;
+  border: #aaaaaa;
   border-style: solid;
   border-top-width: 1px;
   border-right-width: 1px;
   border-bottom-width: 1px;
-  border-left-width: 1px
-}
+  border-left-width: 1px; }
 
-select.worksheet_edit {
-  width:5em;
-    border: #aaaaaa;  
-  border-style: solid;
-  border-top-width: 1px;
-  border-right-width: 1px;
-  border-bottom-width: 1px;
-  border-left-width: 1px
-}
+#worksheet-list {
+  width: 100%;
+  border: 0; }
+#worksheet-list thead {
+  background-color: #E8EEF7;
+  padding: 5px; }
+#worksheet-list thead td.checkbox {
+  padding: 4px; }
 
 td.worksheet_link {
   font-family: sans-serif;
-  font-size:12px;
-  font-weight:bold;  
-  color: #000000;
-}
-
-td.archived_worksheet_link {
+  font-size: 12px;
+  font-weight: bold;
+  color: #000000; }
+td.archived_worksheet_link, td.owner_collab, td.last_edited {
   font-family: sans-serif;
-  font-size:12px;
-  color: #000000;
-}
-
-td.owner_collab {
-  font-family: sans-serif;
-  font-size:12px;
-  color: #000000;
-}
-
-td.last_edited {
-  font-family: sans-serif;
-  font-size:12px;
-  color: #000000;
-}
+  font-size: 12px;
+  color: #000000; }
 
 span.addtext {
   font-family: sans-serif;
-  font-size:13px;
-  color: #222;
-}
+  font-size: 13px;
+  color: #222; }
 
 textarea.plaintextedit {
-    font-family: courier, monospace;
-    font-size:10pt;
-    border: 1px solid #8cacbb;  
-    color: black;
-    background-color: white;
-    overflow: auto;
-    width: 99%;
-    height: 60%;
-}
+  font-family: courier, monospace;
+  font-size: 10pt;
+  border: 1px solid #8cacbb;
+  color: black;
+  background-color: white;
+  overflow: auto;
+  width: 99%;
+  height: 60%; }
 
 pre.plaintext {
-    overflow:auto;
-    font-family: courier, monospace;
-    font-size:10pt;
-    border: 1px solid #8cacbb;  
-    color: black;
-    background-color: white;
-    margin-top: 0.5em;
-}
+  overflow: auto;
+  font-family: courier, monospace;
+  font-size: 10pt;
+  border: 1px solid #8cacbb;
+  color: black;
+  background-color: white;
+  margin-top: 0.5em; }
 
 div.docidx {
-  text-align:center;
+  text-align: center;
   font-family: sans-serif;
-  font-size:16px;
+  font-size: 16px;
   color: #222;
-  font-weight:bold;  
-}
+  font-weight: bold; }
 
 span.ping {
-   display:none;
-}
+  display: none; }
+span.pingdown {
+  font-family: sans-serif;
+  font-size: 15px;
+  font-weight: bold;
+  color: white;
+  background-color: #990000; }
 
-span.pingdown {
-   font-family:sans-serif;
-   font-size:15px;
-   font-weight:bold;
-   color:white;
-   background-color: #990000;   
-}
+/* Scraped directly from pygment. */
+.hll {
+  background-color: #ffffcc; }
 
+.c {
+  color: #408090;
+  font-style: italic; }
 
+.err {
+  border: 1px solid #FF0000; }
 
-/* These have been scraped directly from pygment. */
+.k {
+  color: #007020;
+  font-weight: bold; }
 
-.hll { background-color: #ffffcc }
-.c { color: #408090; font-style: italic } /* Comment */
-.err { border: 1px solid #FF0000 } /* Error */
-.k { color: #007020; font-weight: bold } /* Keyword */
-.o { color: #666666 } /* Operator */
-.cm { color: #408090; font-style: italic } /* Comment.Multiline */
-.cp { color: #007020 } /* Comment.Preproc */
-.c1 { color: #408090; font-style: italic } /* Comment.Single */
-.cs { color: #408090; background-color: #fff0f0 } /* Comment.Special */
-.gd { color: #A00000 } /* Generic.Deleted */
-.ge { font-style: italic } /* Generic.Emph */
-.gr { color: #FF0000 } /* Generic.Error */
-.gh { color: #000080; font-weight: bold } /* Generic.Heading */
-.gi { color: #00A000 } /* Generic.Inserted */
-.go { color: #0000aa } /* Generic.Output */
-.gp { color: #c65d09; font-weight: bold } /* Generic.Prompt */
-.gs { font-weight: bold } /* Generic.Strong */
-.gu { color: #800080; font-weight: bold } /* Generic.Subheading */
-.gt { color: #0040D0 } /* Generic.Traceback */
-.kc { color: #007020; font-weight: bold } /* Keyword.Constant */
-.kd { color: #007020; font-weight: bold } /* Keyword.Declaration */
-.kn { color: #007020; font-weight: bold } /* Keyword.Namespace */
-.kp { color: #007020 } /* Keyword.Pseudo */
-.kr { color: #007020; font-weight: bold } /* Keyword.Reserved */
-.kt { color: #902000 } /* Keyword.Type */
-.m { color: #208050 } /* Literal.Number */
-.s { color: #4070a0 } /* Literal.String */
-.na { color: #4070a0 } /* Name.Attribute */
-.nb { color: #007020 } /* Name.Builtin */
-.nc { color: #0e84b5; font-weight: bold } /* Name.Class */
-.no { color: #60add5 } /* Name.Constant */
-.nd { color: #555555; font-weight: bold } /* Name.Decorator */
-.ni { color: #d55537; font-weight: bold } /* Name.Entity */
-.ne { color: #007020 } /* Name.Exception */
-.nf { color: #06287e } /* Name.Function */
-.nl { color: #002070; font-weight: bold } /* Name.Label */
-.nn { color: #0e84b5; font-weight: bold } /* Name.Namespace */
-.nt { color: #062873; font-weight: bold } /* Name.Tag */
-.nv { color: #bb60d5 } /* Name.Variable */
-.ow { color: #007020; font-weight: bold } /* Operator.Word */
-.w { color: #bbbbbb } /* Text.Whitespace */
-.mf { color: #208050 } /* Literal.Number.Float */
-.mh { color: #208050 } /* Literal.Number.Hex */
-.mi { color: #208050 } /* Literal.Number.Integer */
-.mo { color: #208050 } /* Literal.Number.Oct */
-.sb { color: #4070a0 } /* Literal.String.Backtick */
-.sc { color: #4070a0 } /* Literal.String.Char */
-.sd { color: #4070a0; font-style: italic } /* Literal.String.Doc */
-.s2 { color: #4070a0 } /* Literal.String.Double */
-.se { color: #4070a0; font-weight: bold } /* Literal.String.Escape */
-.sh { color: #4070a0 } /* Literal.String.Heredoc */
-.si { color: #70a0d0; font-style: italic } /* Literal.String.Interpol */
-.sx { color: #c65d09 } /* Literal.String.Other */
-.sr { color: #235388 } /* Literal.String.Regex */
-.s1 { color: #4070a0 } /* Literal.String.Single */
-.ss { color: #517918 } /* Literal.String.Symbol */
-.bp { color: #007020 } /* Name.Builtin.Pseudo */
-.vc { color: #bb60d5 } /* Name.Variable.Class */
-.vg { color: #bb60d5 } /* Name.Variable.Global */
-.vi { color: #bb60d5 } /* Name.Variable.Instance */
-.il { color: #208050 } /* Literal.Number.Integer.Long */
+.o {
+  color: #666666; }
 
-/* end stuff scraped from pygment */
+.cm {
+  color: #408090;
+  font-style: italic; }
+
+.cp {
+  color: #007020; }
+
+.c1 {
+  color: #408090;
+  font-style: italic; }
+
+.cs {
+  color: #408090;
+  background-color: #fff0f0; }
+
+.gd {
+  color: #A00000; }
+
+.ge {
+  font-style: italic; }
+
+.gr {
+  color: #FF0000; }
+
+.gh {
+  color: #000080;
+  font-weight: bold; }
+
+.gi {
+  color: #00A000; }
+
+.go {
+  color: #0000aa; }
+
+.gp {
+  color: #c65d09;
+  font-weight: bold; }
+
+.gs {
+  font-weight: bold; }
+
+.gu {
+  color: #800080;
+  font-weight: bold; }
+
+.gt {
+  color: #0040D0; }
+
+.kc, .kd, .kn {
+  color: #007020;
+  font-weight: bold; }
+
+.kp {
+  color: #007020; }
+
+.kr {
+  color: #007020;
+  font-weight: bold; }
+
+.kt {
+  color: #902000; }
+
+.m {
+  color: #208050; }
+
+.s, .na {
+  color: #4070a0; }
+
+.nb {
+  color: #007020; }
+
+.nc {
+  color: #0e84b5;
+  font-weight: bold; }
+
+.no {
+  color: #60add5; }
+
+.nd {
+  color: #555555;
+  font-weight: bold; }
+
+.ni {
+  color: #d55537;
+  font-weight: bold; }
+
+.ne {
+  color: #007020; }
+
+.nf {
+  color: #06287e; }
+
+.nl {
+  color: #002070;
+  font-weight: bold; }
+
+.nn {
+  color: #0e84b5;
+  font-weight: bold; }
+
+.nt {
+  color: #062873;
+  font-weight: bold; }
+
+.nv {
+  color: #bb60d5; }
+
+.ow {
+  color: #007020;
+  font-weight: bold; }
+
+.w {
+  color: #bbbbbb; }
+
+.mf, .mh, .mi, .mo {
+  color: #208050; }
+
+sb, .sc {
+  color: #4070a0; }
+
+.sd {
+  color: #4070a0;
+  font-style: italic; }
+
+.s2 {
+  color: #4070a0; }
+
+.se {
+  color: #4070a0;
+  font-weight: bold; }
+
+.sh {
+  color: #4070a0; }
+
+.si {
+  color: #70a0d0;
+  font-style: italic; }
+
+.sx {
+  color: #c65d09; }
+
+.sr {
+  color: #235388; }
+
+.s1 {
+  color: #4070a0; }
+
+.ss {
+  color: #517918; }
+
+.bp {
+  color: #007020; }
+
+.vc, .vg, .vi {
+  color: #bb60d5; }
+
+.il {
+  color: #208050; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/master.css
--- a/sagenb/data/sage/css/master.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/master.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,47 +1,35 @@
-@import url('/css/reset.css');
-
+@import url('/css/reset.css')[];
 html {
-font-size:100.1%
-}
+  font-size: 100.1%; }
 
 body {
-font:.9em/1.2em Arial, Helvetica, sans-serif
-}
+  font: .9em/1.2em Arial, Helvetica, sans-serif; }
 
 h1 {
-background:#DCDCDC;
-border-bottom:1px solid #CCC;
-font-size:2em;
-padding:0 5px
-}
+  background: #DCDCDC;
+  border-bottom: 1px solid #CCC;
+  font-size: 2em;
+  padding: 0 5px; }
 
 #buttons {
-background:#DCDCDC;
-padding:5px
-}
+  background: #DCDCDC;
+  padding: 5px; }
 
 h2 {
-font-size:1.5em
-}
+  font-size: 1.5em; }
 
 .section {
-border-bottom:1px solid #CCC;
-padding:5px
-}
-
+  border-bottom: 1px solid #CCC;
+  padding: 5px; }
 .section > div {
-max-width:350px;
-text-align:right
-}
+  max-width: 350px;
+  text-align: right; }
 
 td {
-padding-left:5px
-}
+  padding-left: 5px; }
 
 input.c1 {
-width:200px
-}
+  width: 200px; }
 
 strong {
-font-weight: bold
-}
\ No newline at end of file
+  font-weight: bold; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/registration.css
--- a/sagenb/data/sage/css/registration.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/registration.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,69 +1,54 @@
-/***** Global Settings *****/
-
-html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,font,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,dl,dt,dd,ol,ul,li,table,caption,tbody,tfoot,thead,tr,th,td {
-border:0;
-font-family:inherit;
-font-size:100%;
-font-style:inherit;
-font-weight:inherit;
-margin:0;
-outline:0;
-padding:0;
-text-decoration:none;
-vertical-align:baseline
-}
+html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, dl, dt, dd, ol, ul, li, table, caption, tbody, tfoot, thead, tr, th, td {
+  border: 0;
+  font-family: inherit;
+  font-size: 100%;
+  font-style: inherit;
+  font-weight: inherit;
+  margin: 0;
+  outline: 0;
+  padding: 0;
+  text-decoration: none;
+  vertical-align: baseline; }
 
 html {
-font-size:100.1%
-}
+  font-size: 100.1%; }
 
 body {
-font:0.88em/1.4 Arial, Helvetica, sans-serif;
-}
+  font: 0.88em/1.4 Arial, Helvetica, sans-serif; }
 
 #wrapper {
-margin:0 auto;
-max-width:600px
-}
+  margin: 0 auto;
+  max-width: 600px; }
 
-/***** Headings *****/
-
-h1,h2,h3,h4,h5 {
-font-wieght:normal
-}
+h1, h2, h3, h4, h5 {
+  font-wieght: normal; }
 
 h1 {
-border-bottom:1px solid #696969;
-font-size:2em;
-padding:10px 0
-}
+  border-bottom: 1px solid #696969;
+  font-size: 2em;
+  padding: 10px 0; }
 
 h2 {
-font-weight:bold
-}
+  font-weight: bold; }
 
-h1, h2, p, li, .entry {
-margin-bottom:10px
-}
+h1, h2, p, li {
+  margin-bottom: 10px; }
 
 .entry {
-border:1px solid #999;
-padding:3px;
-width:200
-}
+  margin-bottom: 10px;
+  border: 1px solid #999;
+  padding: 3px;
+  width: 200; }
 
 li {
-border-bottom:1px solid #CCC
-}
+  border-bottom: 1px solid #CCC; }
 
-.error, .error_found {
-color:red
-}
+.error {
+  color: red; }
 
 .error_found {
-font-size:1.5em 
-}
+  color: red;
+  font-size: 1.5em; }
 
 .button {
-font-size:1.2em
-}
+  font-size: 1.2em; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/reset.css
--- a/sagenb/data/sage/css/reset.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/reset.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,38 +1,31 @@
-html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,font,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td {
-border:0;
-font-family:inherit;
-font-size:100%;
-font-style:inherit;
-font-weight:inherit;
-margin:0;
-outline:0;
-padding:0;
-text-decoration:none;
-vertical-align:baseline
-}
+html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {
+  border: 0;
+  font-family: inherit;
+  font-size: 100%;
+  font-style: inherit;
+  font-weight: inherit;
+  margin: 0;
+  outline: 0;
+  padding: 0;
+  text-decoration: none;
+  vertical-align: baseline; }
 
-:focus {
-outline:0
-}
-
-ol,ul {
-list-style:none
-}
+ol, ul {
+  list-style: none; }
 
 table {
-border-collapse:separate;
-border-spacing:0
-}
+  border-collapse: separate;
+  border-spacing: 0; }
 
-caption,th,td {
-font-weight:normal;
-text-align:left
-}
+caption, th, td {
+  font-weight: normal;
+  text-align: left; }
 
-blockquote:before,blockquote:after,q:before,q:after {
-content:""
-}
+blockquote:before, blockquote:after {
+  content: ""; }
 
-blockquote,q {
-quotes:"" ""
-}
\ No newline at end of file
+q:before, q:after {
+  content: ""; }
+
+blockquote, q {
+  quotes: "" ""; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/css/user_management.css
--- a/sagenb/data/sage/css/user_management.css	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/css/user_management.css	Sat Oct 24 12:07:30 2009 +0800
@@ -1,5 +1,3 @@
-@import url('/css/master.css');
-
+@import url('/css/master.css')[];
 body {
-margin:10px
-}
\ No newline at end of file
+  margin: 10px; }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/banner.html
--- a/sagenb/data/sage/html/banner.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/banner.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,18 +1,10 @@
 
 <div class="banner">
-  <table width="100%">
-    <tr>
-      <td>
-        <a class="banner" href="http://nb.sagemath.org/"><img align="top" src="/images/sagenb.png" alt="Sage"> The Sage Notebook</a>
-<br>
-      </td>
-      <td>
+    <a class="banner" href="http://nb.sagemath.org/">
+        <img align="top" src="/images/sagenb.png" alt="Sage" /> The Sage Notebook
+    </a>
 	<span class="ping" id="ping">Searching for Sage server...</span>
-      </td>
-    </tr>
-    <tr>
-      <td style="font-size:xx-small; text-indent:13px;color:black">Version {{ sage_version }}</td>
-      <td></td>
-    </tr>
-  </table>
+    <div class="version">
+        Version {{ sage_version }}
+    </div>
 </div>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/base.html
--- a/sagenb/data/sage/html/base.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/base.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,4 +1,3 @@
-
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
 <html lang="en">
     <head>
@@ -7,7 +6,19 @@
         {% block pre_main_css %}{% endblock %}
         <link type="text/css" rel="stylesheet" href="/css/{% block css %}master{% endblock %}.css" media="screen" />
         {% block more_css %}{% endblock %}
-        {% block javascript %}{% endblock %}
+        {% block javascript %}
+        {% if not pub %}
+          <script type="text/javascript" src="/javascript/jquery/jquery-1.3.2.min.js"></script>
+        {% endif %}
+          <script type="text/javascript" src="/javascript/main.js"></script>
+        {% if not pub %}
+          <script type="text/javascript">
+              var worksheet_filenames = {{ worksheet_filenames }}; 
+          </script>
+          <script type="text/javascript" src="/javascript/gears/gears_init.js"></script> 
+          <script type="text/javascript" src="/javascript/gears/shortcut.js"></script> 
+        {% endif %}
+        {% endblock %}
     </head>
     <body {% block body_attrs %}{% endblock %}>
         {% block body %}{% endblock %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/list_top.html
--- a/sagenb/data/sage/html/list_top.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/list_top.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,6 +1,6 @@
 {% include "html/top_bar.html" %}
 
-
+<div id="usercontrols">
 {% if pub is not defined or not pub %}
 <a class="boldusercontrol" href="/new_worksheet" target="_blank">New Worksheet</a>
 <a class="boldusercontrol" href="/upload">Upload</a>
@@ -9,8 +9,6 @@
 {% endif %}
 {% endif %}
 
+
 {% include "html/search.html" %}
-
-<br>
-<hr class="usercontrol">
-
+</div>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/afterpublish_window.html
--- a/sagenb/data/sage/html/notebook/afterpublish_window.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/afterpublish_window.html	Sat Oct 24 12:07:30 2009 +0800
@@ -14,6 +14,17 @@
 
 {% set checked = 'checked="true"' if worksheet.is_auto_publish() else '' %}
 
-{% set title = 'Worksheet is publicly viewable at <a href="%s" style="color:#FFF" target="_blank">%s</a><br />Published on %s<br/><br /><input type="button" value="Re-publish worksheet" onClick="parent.location=\'?re\'"><input type="button" value="Stop publishing" style="margin-left:5px" onClick="parent.location=\'?stop\'"><br /><br /><input type="checkbox" name="auto" %s onchange="parent.location=\'?auto\'"/> Automatically re-publish when changes are made'|format(url, url, time, checked) %}
+{% block sharebar_title %}
+Worksheet is publicly viewable at <a href="{{ url }}" style="color:#FFF" target="_blank">{{ url }}</a>
+<br />
+Published on {{ time }}
+<br />
+<br />
+<input type="button" value="Re-publish worksheet" onClick="parent.location='?re'" />
+<input type="button" value="Stop publishing" style="margin-left:5px" onClick="parent.location='?stop'" />
+<br /><br />
+<input type="checkbox" name="auto" {{ checked }} onchange="parent.location='?auto'"/> <label for="auto">Automatically re-publish when changes are made</label>
+{% endblock %}
 {% set select = "publish" %}
 {% set backwards = true %}
+
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/beforepublish_window.html
--- a/sagenb/data/sage/html/notebook/beforepublish_window.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/beforepublish_window.html	Sat Oct 24 12:07:30 2009 +0800
@@ -10,6 +10,21 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = '<p>You can publish your worksheet to the Internet, where anyone will be able to access and view it online.</p><p>Your worksheet will be assigned a unique address (URL) that you can send to your friends and colleagues.</p><p>Do you want to publish this worksheet?</p><form method="get" action="."><input type="hidden" name="yes" value="" /><input type="submit" value="Yes" style="margin-left:10px" /><input type="button" value="No" style="margin-left:5px" onClick="parent.location=\'../\'"><br/><br/><input type="checkbox" name="auto" style="margin-left:13px" /> Automatically re-publish when changes are made</form>' %}
+{% block sharebar_title %}
+<p>You can publish your worksheet to the Internet, where anyone will be able to access and view it online.</p>
+
+<p>Your worksheet will be assigned a unique address (URL) that you can send to your friends and colleagues.</p>
+
+<p>Do you want to publish this worksheet?</p>
+
+<form method="get" action=".">
+    <input type="hidden" name="yes" value="" />
+    <input type="submit" value="Yes" style="margin-left:10px" />
+    <input type="button" value="No" style="margin-left:5px" onClick="parent.location='../'" />
+    <br/>
+    <br/>
+    <input type="checkbox" name="auto" style="margin-left:13px" /> Automatically re-publish when changes are made
+</form>
+{% endblock %}
 {% set select = "publish" %}
 {% set backwards = true %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/download_or_delete_datafile.html
--- a/sagenb/data/sage/html/notebook/download_or_delete_datafile.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/download_or_delete_datafile.html	Sat Oct 24 12:07:30 2009 +0800
@@ -15,9 +15,12 @@
 - JEDITABLE_TINYMCE - a boolean stating whether to include jEditable and TinyMCE
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
-{% set title = "Data file: %s"|format(filename_) %}
 
-{% block body_addition %}
+{% block sharebar_title %}
+Data file: {{ filename_ }}
+{% endblock %}
+
+{% block after_sharebar %}
 <p>You may download <a href="{{ path }}">{{ filename_ }}</a> or create a linked copy to the worksheet <select onchange="go_option(this);" class="worksheet">
 <option selected>select worksheet</option>
 {% for worksheet in active_worksheets %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/edit_window.html
--- a/sagenb/data/sage/html/notebook/edit_window.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/edit_window.html	Sat Oct 24 12:07:30 2009 +0800
@@ -12,13 +12,15 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = 'Edit plain text &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="submit" value="Save Changes" name="button_save" id="button_save"> <input type="submit" value="Cancel" name="button_cancel">' %}
+{% block sharebar_title %}
+Edit plain text &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="submit" value="Save Changes" name="button_save" id="button_save"> <input type="submit" value="Cancel" name="button_cancel">
+{% endblock %}
 {% set select = "edit" %}
 
 {% block before_sharebar %}
 <form method="post" action="save" enctype="multipart/form-data">
 {% endblock %}
-{% block body_addition %}
+{% block after_sharebar %}
 <script type="text/javascript">
     function save_worksheet() {
     }
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/head.tmpl
--- a/sagenb/data/sage/html/notebook/head.tmpl	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/head.tmpl	Sat Oct 24 12:07:30 2009 +0800
@@ -9,19 +9,13 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
   #}
 {% macro common_title(worksheet_filename, worksheet) %}
-    {% if worksheet_filename %}
+    {% if worksheet and worksheet.name() %}
         {{ worksheet.name() }} (Sage)
     {% else %}
         Sage Notebook | Welcome
     {% endif %}
 {% endmacro %}
 
-
-{% macro common_css %}
-<!-- Sage notebook stylesheet -->
-<link rel=stylesheet href="/css/main.css" type="text/css" />
-{% endmacro %}
-
 {% macro common_javascript(worksheet, worksheet_filename, username, JSMATH, JSMATH_IMAGE_FONTS, JEDITABLE_TINYMCE, sage_jsmath_macros) %}
 <!-- jQuery - general-purpose functions -->
 <script type="text/javascript" src="/javascript/jquery/jquery-1.3.2.min.js"></script>
@@ -55,7 +49,7 @@
     <script type="text/javascript" src="/javascript/jsmath/jsMath.js"></script>
     <script type="text/javascript">
         /* The extensions here do the following:
-            - verb implements the \verb command: 
+            - verb implements the \verb command:
               see http://www.math.union.edu/~dpvc/jsMath/authors/verb.html
             - moreArrows implements \xrightarrow, among other things:
               see http://www.math.union.edu/~dpvc/jsMath/authors//moreArrows.html
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/index.html
--- a/sagenb/data/sage/html/notebook/index.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/index.html	Sat Oct 24 12:07:30 2009 +0800
@@ -2,15 +2,21 @@
 {#
 INPUT:
 - worksheet - an instance of Worksheet
-- worksheet_filename - a string containing a worksheet's filename
-- worksheet_html - a string containing the html for the worksheet
 - notebook - an instance of Notebook which contains worksheet
-- username - a string containing a username
+- username  - a string containing a username
 - show_debug - a boolean stating whether to show debug information
-- JSMATH - a boolean stating whether to include jsMath
+  - JSMATH - a boolean stating whether to include jsMath
 - JSMATH_IMAGE_FONTS - a boolean stating whether to include jsMath iamage fonts
 - JEDITABLE_TINYMCE - a boolean stating whether to include jEditable and TinyMCE
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
+- do_print - a boolean stating whether the file is for print mode
+- worksheet_filename - a string containing a worksheet's filename
+- worksheet_html - a string containing the html for a worksheet
+- select    - a string containing the control that is selected
+- backwards - a boolean
+- backwards - a boolean
+- warn - boolean stating whether to warn that another user is viewing
+         the worksheet
 #}
 
 {% if not select %}
@@ -21,7 +27,7 @@
     {% set backwards = false %}
 {% endif %}
     
-{% include "html/notebook/head.tmpl" %}
+{% from "html/notebook/head.tmpl" import common_title, common_css, common_javascript %}
 
 {% block title %}
 {{ common_title(worksheet_filename, worksheet) }}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/plain_text_window.html
--- a/sagenb/data/sage/html/notebook/plain_text_window.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/plain_text_window.html	Sat Oct 24 12:07:30 2009 +0800
@@ -11,9 +11,12 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = "View plain text" %}
+{% block sharebar_title %}
+View plain text
+{% endblock %}
+
 {% set select = "text" %}
 
-{% block body_addition %}
+{% block after_sharebar %}
 <pre class="plaintext" id="cell_intext" name="textfield">{{ plain_text }}</pre>
 {% endblock %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/specific_revision.html
--- a/sagenb/data/sage/html/notebook/specific_revision.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/specific_revision.html	Sat Oct 24 12:07:30 2009 +0800
@@ -16,7 +16,9 @@
 #}
 
 {% set select = "revisions" %}
-{% set title = "Revision from %s ago&nbsp;&nbsp;&nbsp;&nbsp;<a href='revisions'>Revision List</a>"|format(time_ago) %}
+{% block sharebar_title %}
+Revision from {{ time_ago }} ago&nbsp;&nbsp;&nbsp;&nbsp;<a href='revisions'>Revision List</a>
+{% endblock %}
     
 {% macro actions %}
 {% if prev_rev %}
@@ -35,7 +37,7 @@
 <a class="listcontrol" href="revisions?rev={{ rev }}&action=publish">Publish this one</a>&nbsp;&nbsp;
 {% endmacro %}
 
-{% block body_addition %}
+{% block after_sharebar %}
 {{ actions() }}
 <hr class="usercontrol" />        
 <table width="100%%">
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/top_bar_and_worksheet.html
--- a/sagenb/data/sage/html/notebook/top_bar_and_worksheet.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/top_bar_and_worksheet.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,27 +1,18 @@
 {#
 INPUT:
-- username - a string containing a username
+- username  - a string containing a username
 - worksheet_filename - a string containing a worksheet's filename
 - worksheet_html - a string containing the html for a worksheet
 - show_debug - a boolean stating whether to show debug information
-  #}
-{% include "html/notebook/user_controls.tmpl" %}
-{% include "html/notebook/worksheet_topbar.tmpl" %}
-{% set entries = [("$('#topbar').toggle()", 'Toggle', 'Toggle the top bar'),
-                       ('/', 'Home', 'Back to your personal worksheet list'),
-                       ('/pub', 'Published', 'Browse the published worksheets'),
-                       ('history_window()', 'Log', 'View a log of recent computations'),
-                       ('/settings', 'Settings', 'Account Settings'), 
-                       ('bugreport()', 'Report a Problem', 'Report a problem or submit a bug to improve Sage'),
-                       ('help()', 'Help', 'Documentation'),
-                       ('/logout', 'Sign out', 'Log out of the Sage notebook')] %}
-<table width="100%">
-    <tr>
-        <td>{% include "html/banner.html" %}</td>
-        <td align="right">{{ user_controls(username, entries) }}</td>
-    </tr>
-</table>
-{% if worksheet_filename %}
+  - worksheet - an instance of Worksheet
+- select    - a string containing the control that is selected
+- backwards - a boolean
+- backwards - a boolean
+#}
+{% from "html/notebook/worksheet_topbar.tmpl" import worksheet_topbar %}
+{% set toggle=true %}
+{% include "html/top_bar.html" %}
+{% if worksheet.filename() %}
 {{ worksheet_topbar(worksheet, "use", username) }}
 {% endif %}
 {% if show_debug %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/upload_data_window.html
--- a/sagenb/data/sage/html/notebook/upload_data_window.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/upload_data_window.html	Sat Oct 24 12:07:30 2009 +0800
@@ -10,9 +10,11 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = 'Upload or Create Data File' %}
+{% block sharebar_title %}
+Upload or Create Data File
+{% endblock %}
 
-{% block body_addition %}
+{% block after_sharebar %}
 <div class="upload_worksheet_menu" id="upload_worksheet_menu">
     <h1><font size=+1>Upload or create data file attached to the worksheet '{{ worksheet.name() }}' </font></h1>
     <hr />
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/user_controls.tmpl
--- a/sagenb/data/sage/html/notebook/user_controls.tmpl	Fri Oct 23 18:06:28 2009 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-
-{% macro user_controls(user, entries) %}
-    <span class="username">{{ user }}</span>
-    {% for href, name, title in entries %}
-        {% if '(' in href %}
-            {% set action = 'onClick="' ~ href ~ '"' %}
-        {% else %}
-            {% set action = 'href="' ~ href ~ '"' %}
-        {% endif %}
-        <span class="vbar"></span>
-        <a title="{{ title }}" class="usercontrol" {{ action }}>{{ name }}</a>
-    {% endfor %}
-{% endmacro %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_page_template.html
--- a/sagenb/data/sage/html/notebook/worksheet_page_template.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/worksheet_page_template.html	Sat Oct 24 12:07:30 2009 +0800
@@ -3,7 +3,7 @@
 INPUT:
 - worksheet - an instance of Worksheet
 - worksheet_filename - a string containing a worksheet's filename
-- username - a string containing a username
+- username  - a string containing a username
 - title - a string
 - select    - a string containing the control that is selected
 - backwards - a boolean
@@ -21,9 +21,8 @@
     {% set backwards = false %}
 {% endif %}
     
-{% include "html/notebook/head.tmpl" %}
-{% include "html/notebook/worksheet_top.tmpl" %}
-{% include "html/notebook/worksheet_topbar.tmpl" %}
+{% from "html/notebook/head.tmpl" import common_title, common_css, common_javascript %}
+{% from "html/notebook/worksheet_topbar.tmpl" import worksheet_topbar %}
 
 {% block title %}
 {{ common_title(worksheet_filename, worksheet) }}
@@ -36,11 +35,13 @@
 {% endblock %}
 
 {% block body %}
-{{ worksheet_top(username) }}
+{% set toggle=true %}
+{% include "html/top_bar.html" %}
 {{ worksheet_topbar(worksheet, select, username, backwards) }}
 <hr class="usercontrol" />
 {% block before_sharebar %}{% endblock %}
-<span class="sharebar">{{ title }}</span>
+<span class="sharebar">{% block sharebar_title %}{% endblock %}</span>
 <br /><br /><br />
-{% block body_addition %}{% endblock %}
+{% block after_sharebar %}{% endblock %}
 {% endblock %}
+
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_revision_list.html
--- a/sagenb/data/sage/html/notebook/worksheet_revision_list.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/worksheet_revision_list.html	Sat Oct 24 12:07:30 2009 +0800
@@ -12,10 +12,13 @@
   #}
 
 
-{% set title  = "Revision History" %}
+{% block sharebar_title %}
+Revision History
+{% endblock %}
+
 {% set select = "revisions" %}
 
-{% block body_addition %}
+{% block after_sharebar %}
 <hr class="usercontrol">
 <table width="100%%">
     <tr>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_settings.html
--- a/sagenb/data/sage/html/notebook/worksheet_settings.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/worksheet_settings.html	Sat Oct 24 12:07:30 2009 +0800
@@ -10,12 +10,14 @@
 - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = 'Worksheet Settings &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button name="button_save">Save Settings</button>  <input type="submit" value="Cancel" name="button_cancel"/>' %}
+{% block sharebar_title %}
+Worksheet Settings &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button name="button_save">Save Settings</button>  <input type="submit" value="Cancel" name="button_cancel"/>
+{% endblock %}
 
 {% block before_sharebar %}
-<form width=70%% method="post" action="input_settings"  enctype="multipart/form-data">
+<form width=70% method="post" action="input_settings"  enctype="multipart/form-data">
 {% endblock %}
-{% block body_addition %}
+{% block after_sharebar %}
 </form>
 {% endblock %}
 
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_share.html
--- a/sagenb/data/sage/html/notebook/worksheet_share.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/worksheet_share.html	Sat Oct 24 12:07:30 2009 +0800
@@ -12,10 +12,13 @@
     - sage_jsmath_macros - an array containing strings of Javascript of Sage macros for jsMath
 #}
 
-{% set title = "Share this document" %}
+{% block sharebar_title %}
+Share this document
+{% endblock %}
+
 {% set select = "share" %}
 
-{% block body_addition %}
+{% block after_sharebar %}
 {% if not (user_is_admin or username == worksheet.owner()) %}
     Only the owner of a worksheet is allowed to share it. You can do whatever you want if you <a href="copy">make your own copy</a>.
 {% else %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_top.tmpl
--- a/sagenb/data/sage/html/notebook/worksheet_top.tmpl	Fri Oct 23 18:06:28 2009 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-{#
-INPUT:
-- username - a string containing a username
-#}
-
-{% macro worksheet_top(username) %}
-{% include "html/notebook/user_controls.tmpl" %}
-{% include "html/notebook/worksheet_topbar.tmpl" %}
-{% set entries = [("$('#topbar').toggle()", 'Toggle', 'Toggle the top bar'),
-                       ('/', 'Home', 'Back to your personal worksheet list'),
-                       ('/pub', 'Published', 'Browse the published worksheets'),
-                       ('history_window()', 'Log', 'View a log of recent computations'),
-                       ('/settings', 'Settings', 'Account Settings'), 
-                       ('bugreport()', 'Report a Problem', 'Report a problem or submit a bug to improve Sage'),
-                       ('help()', 'Help', 'Documentation'),
-                       ('/logout', 'Sign out', 'Log out of the Sage notebook')] %}
-<table width="100%">
-    <tr>
-        <td>{% include "html/banner.html" %}</td>
-        <td align="right">{{ user_controls(username, entries) }}</td>
-    </tr>
-</table>
-{% endmacro %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/notebook/worksheet_topbar.tmpl
--- a/sagenb/data/sage/html/notebook/worksheet_topbar.tmpl	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/notebook/worksheet_topbar.tmpl	Sat Oct 24 12:07:30 2009 +0800
@@ -1,35 +1,48 @@
-
 {#
 INPUT:
 - worksheet - an instance of Worksheet
 - select    - a string containing the control that is selected
 - username  - a string containing a username
 - backwards - a boolean
-  #}
-{% macro worksheet_topbar(worksheet, select=None, username='guest', backwards=false) %}
-    <table width="100%%" id="topbar">
-        <tr>
-            <td align="left"> {{ worksheet.html_title(username) }} </td>
-            <td align="right"> {{ worksheet.html_save_discard_buttons() }} </td>
-        </tr>
-        <tr>
-            <td align="left"> {{ worksheet.html_menu() }} </td>
-            <td align="right"> {{ worksheet.html_share_publish_buttons(select, backwards) }}</td>
-        </tr>
-    </table>
-    <div class="hidden" id="slide_controls">
-        <div class="slideshow_control">
-            <a class="slide_arrow" onClick="slide_next()">&gt;</a>
-            <a class="slide_arrow" onClick="slide_last()">&gt;&gt;</a> <span class="vbar"></span>
-            <a class="cell_mode" onClick="cell_mode()">Exit</a>
-        </div>
-        <div class="slideshow_progress" id="slideshow_progress" onClick="slide_next()">
-            <div class="slideshow_progress_bar" id="slideshow_progress_bar">&nbsp;</div>
-            <div class="slideshow_progress_text" id="slideshow_progress_text">&nbsp;</div>
-        </div>
-        <div class="slideshow_control">
-            <a class="slide_arrow" onClick="slide_first()">&lt;&lt;</a>
-            <a class="slide_arrow" onClick="slide_prev()">&lt;</a>
-        </div>
-    </div> 
+#}
+{% macro worksheet_topbar(worksheet, select=None, username='guest',
+backwards=false, warn=false) %}
+<div id="worksheet-bar">
+    <div class="worksheet_title">
+        <a id="worksheet_title" class="worksheet_title"
+           onClick="rename_worksheet(); return false;"
+           title="Click to rename this worksheet">
+            {{ worksheet.name() }}
+        </a>
+        <br> {{ worksheet.html_time_last_edited() }}
+        {% if worksheet.warn_about_other_person_editing(username) and username != 'guest' and not worksheet.is_doc_worksheet() %}
+        &nbsp;&nbsp;<span class="pingdown">(Someone else is viewing this worksheet)</span>
+        {% endif %}
+    </div>
+    <div id="save-discard-buttons">
+        {{ worksheet.html_save_discard_buttons() }}
+    </div>
+    
+    <div id="worksheet-menu">
+        {{ worksheet.html_menu() }}
+    </div>
+    <div id="share-publish-buttons">
+        {{ worksheet.html_share_publish_buttons(select, backwards) }}
+    </div>
+</div>
+<div class="hidden" id="slide_controls">
+    <div class="slideshow_control">
+        <a class="slide_arrow" onClick="slide_next()">&gt;</a>
+        <a class="slide_arrow" onClick="slide_last()">&gt;&gt;</a> <span class="vbar"></span>
+        <a class="cell_mode" onClick="cell_mode()">Exit</a>
+    </div>
+    <div class="slideshow_progress" id="slideshow_progress" onClick="slide_next()">
+        <div class="slideshow_progress_bar" id="slideshow_progress_bar">&nbsp;</div>
+        <div class="slideshow_progress_text" id="slideshow_progress_text">&nbsp;</div>
+    </div>
+    <div class="slideshow_control">
+        <a class="slide_arrow" onClick="slide_first()">&lt;&lt;</a>
+        <a class="slide_arrow" onClick="slide_prev()">&lt;</a>
+    </div>
+</div> 
 {% endmacro %}
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/search.html
--- a/sagenb/data/sage/html/search.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/search.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,5 +1,4 @@
-
 <span class="flush-right">
-<input id="search_worksheets" size=20 onkeypress="return search_worksheets_enter_pressed(event, '{{ typ }}');" value="{{ search }}"></input>
+<input id="search_worksheets" size=20 onkeypress="return search_worksheets_enter_pressed(event, '{{ typ }}');" value="{{ search if search else "" }}"></input>
 <button class="add_new_worksheet_menu" onClick="search_worksheets('{{ typ }}');">Search Worksheets</button>
 </span>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/top_bar.html
--- a/sagenb/data/sage/html/top_bar.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/top_bar.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,27 +1,25 @@
-<table width="100%%">
-  <tr>
-    <td>
-      {% include "html/banner.html" %}
-    </td>
-    <td align=right id=controls>
-      <span class="username">{{ username }}</span>
-
-      {% if username == 'guest' %}
-        <span class="vbar"></span><a title="Please log in to the Sage notebook" class="usercontrol" href="/">Log in</a>
-      {% else %}
-        <span class="vbar"></span><a title="Back to your personal worksheet list" class="usercontrol" href="/home/{{ username }}">Home</a>
+<div id="top-bar">
+  {% include "html/banner.html" %}
+  <div id="controls">
+    <span class="username">{{ username }}</span>
+    {% if username == 'guest' %}
+        <a ttile="Please log in to the Sage notebook" class="usercontrol" href="/">Log in</a>
+    {% else %}
+        {# TODO: Hack-ish. Remove on template cleanup. #}
+        {% if toggle %}
+        <a title="Toggle the top bar" class="usercontrol" onClick="$('#worksheet-bar').toggle()">Toggle</a>
+        {% endif %}
+        <a title="Back to your personal worksheet list" class="usercontrol" href="/home/{{ username }}">Home</a>
         {% if pub %}
-          <span class="vbar"></span><span class="usercontrol">Published</span>
+          <span class="usercontrol">Published</span>
         {% else %}
-          <span class="vbar"></span><a title="Browse the published worksheets" class="usercontrol" href="/pub">Published</a>
-          <span class="vbar"></span><a title="View a log of recent computations" class="usercontrol" onClick="history_window()">Log</a>
+          <a title="Browse the published worksheets" class="usercontrol" href="/pub">Published</a>
+          <a title="View a log of recent computations" class="usercontrol" href="#" onClick="history_window()">Log</a>
         {% endif %}
-
-        <span class="vbar"></span><a title="Documentation" class="usercontrol" onClick="help()">Help</a>
-        <span class="vbar"></span><a title="Change account settings including password" class="usercontrol" href="/settings">Settings</a>
-        <span class="vbar"></span><a title="Log out of the Sage notebook" class="usercontrol" href="/logout">Sign out</a>
-      {% endif %}
-    </td>
-  </tr>
-</table>
-<hr class="usercontrol">
+        <a title="Change account settings including password" class="usercontrol" href="/settings">Settings</a>
+        <a title="Documentation" class="usercontrol" href="#" onClick="help()">Help</a>
+        <a title="Report a problem or submit a bug to improve Sage" class="usercontrol" href="#" onClick="bugreport()">Report a Problem</a>
+        <a title="Log out of the Sage notebook" class="usercontrol" href="/logout">Sign out</a>
+    {% endif %}
+  </div>
+</div>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/worksheet/share_publish_buttons.html
--- a/sagenb/data/sage/html/worksheet/share_publish_buttons.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/worksheet/share_publish_buttons.html	Sat Oct 24 12:07:30 2009 +0800
@@ -9,10 +9,10 @@
 {% macro cls(x) %}
 {{ "control-select" if x == select else "control" }}
 {% endmacro %}
-{% macro backwards_text %}
+{% macro backwards_text() %}
 {{ "../" if backwards else "" }}
 {% endmacro %}
-<a title="Print this worksheet" class="usercontrol" onClick="print_worksheet()"><img border=0 src="/images/icon_print.gif" alt="Print">Print</a>
+<a title="Print this worksheet" class="print-link" onClick="print_worksheet()"><img border=0 src="/images/icon_print.gif" alt="Print">Print</a>
 <a class="{{ cls('use') }}" title="Interactively use this worksheet" onClick="edit_worksheet();">Worksheet</a>        
 <a class="{{ cls('edit') }}" title="Edit text version of this worksheet" href="{{ backwards_text() }}edit">Edit</a>
 <a class="{{ cls('text') }}" title="View plain text version of this worksheet" href="{{ backwards_text() }}text">Text</a>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/worksheet/title.html
--- a/sagenb/data/sage/html/worksheet/title.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/worksheet/title.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,10 +1,8 @@
 {#
+MARKED FOR DELETION.
 - worksheet - Worksheet instance
 - name - escaped name of the worksheet
 - username - string of username
-- doc_worksheet - boolean stating whether the worksheet is the doc worksheet
-- warn - boolean stating whether to warn that another user is viewing
-         the worksheet
 #}
 <div class="worksheet_title">
      <a id="worksheet_title" class="worksheet_title" onClick="rename_worksheet(); return false;" title="Click to rename this worksheet">{{ name }}</a>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/data/sage/html/worksheet_listing.html
--- a/sagenb/data/sage/html/worksheet_listing.html	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/data/sage/html/worksheet_listing.html	Sat Oct 24 12:07:30 2009 +0800
@@ -1,5 +1,9 @@
 {% extends "html/base.html" %}
-
+{#
+INPUT:
+- pub - a boolean stating whether to show in public mode.
+- typ - a string stating what kind of worksheets this listing shows
+#}
 {% if pub %}
   {% set worksheet_heading='Published Worksheets' %}
 {% elif typ == 'trash' %}
@@ -37,8 +41,9 @@
 
 {% include "html/list_top.html" %}
 
-
+<div id="worksheet-list-controls">
 {% if not pub %}
+    <div class="action-buttons">
     {% if typ == 'archive' %}
     <button onClick="make_active_button();" title="Unarchive selected worksheets so it appears in the default worksheet list">Unarchive</button>
     {% else %}
@@ -55,8 +60,8 @@
     {% if not accounts %}
     <button onClick="download_worksheets_button();" title="Download selected worksheets">Download</button>
     {% endif %}
-    <span style="padding-left:100px;">
-
+    </div>
+    <div class="folders">
     Current Folder:
     <a class="{{ 'bold' if typ == 'active' else '' }}usercontrol" href=".">Active</a>
     <a class="{{ 'bold' if typ == 'archive' else '' }}usercontrol" href=".?typ=archive">Archived</a>
@@ -65,17 +70,16 @@
     {% if typ == 'trash' %}
     <a class="boldusercontrol" onClick="empty_trash();return false;" href="">(Empty Trash)</a>
     {% endif %}
+    </div>
+{% endif %}
+</div>
 
-    </span>
-{% endif %}
- 
-<br><br>
-
-<table width="100%" border=0 cellspacing=0 cellpadding=0>
-  <tr class="greybox"><td colspan=4><div class="thinspace"></div></td></tr>
-  <tr class="greybox">
+<table cellspacing="0" cellpadding="0" id="worksheet-list">
+  <thead>
     {% if not pub %}
-    <td><input id="controlbox" onClick="set_worksheet_list_checks();" class="entry" type=checkbox></td>
+    <td class="checkbox">
+        <input id="controlbox" onClick="set_worksheet_list_checks();" class="entry" type="checkbox">
+    </td>
     {% else %}
     <td><a class="listcontrol" href=".?sort=rating">Rating</a></td>
     {% endif %}
@@ -97,10 +101,7 @@
       Last Edited
       </a>
     </td>
-  </tr>
-
-  <tr class="greybox"><td colspan=4><div class="thinspace"></div></td></tr>
-
+  </thead>
   {% if not worksheets %}
     {% if pub %}
     <tr>
@@ -205,8 +206,6 @@
 	{{ worksheet.html_time_since_last_edited() }}
       </td>
     </tr>
-    
-    <tr class="thingreybox"><td colspan=4><div class="ultrathinspace"></div></td></tr>
     {% endfor %}
   {% endif %}
   </table>
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/notebook/template.py
--- a/sagenb/notebook/template.py	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/notebook/template.py	Sat Oct 24 12:07:30 2009 +0800
@@ -15,14 +15,14 @@
 #                  http://www.gnu.org/licenses/
 #############################################################################
 
-import jinja
+import jinja2
 import os, sys
 
 from sagenb.misc.misc import SAGE_VERSION, DATA
 
 
 TEMPLATE_PATH = os.path.join(DATA, 'sage')
-env = jinja.Environment(loader=jinja.FileSystemLoader(TEMPLATE_PATH))
+env = jinja2.Environment(loader=jinja2.FileSystemLoader(TEMPLATE_PATH))
 
 def contained_in(container):
     """
@@ -52,11 +52,11 @@
 
 #A dictionary containing the default context
 #The values in this dictionary will be updated
-#by the 
+#by the
 default_context = {'sitename': 'Sage Notebook',
                    'sage_version': SAGE_VERSION}
 
-def template(filename, **user_context): 
+def template(filename, **user_context):
     """
     Returns HTML, CSS, etc., for a template file rendered in the given
     context.
@@ -70,7 +70,7 @@
       the file's template variables
 
     OUTPUT:
-      
+    
     - a string - the rendered HTML, CSS, etc.
 
     EXAMPLES::
@@ -89,9 +89,9 @@
     """
     try:
         tmpl = env.get_template(filename)
-    except jinja.exceptions.TemplateNotFound:
+    except jinja2.exceptions.TemplateNotFound:
         return "Notebook Bug -- missing template %s"%filename
     context = dict(default_context)
     context.update(user_context)
-    r = tmpl.render(**context) 
+    r = tmpl.render(**context)
     return r.encode('utf-8')
diff -r 5f1705b928fc -r 6fa6cce9bd44 sagenb/notebook/worksheet.py
--- a/sagenb/notebook/worksheet.py	Fri Oct 23 18:06:28 2009 -0700
+++ b/sagenb/notebook/worksheet.py	Sat Oct 24 12:07:30 2009 +0800
@@ -2386,17 +2386,6 @@
             name = name[:max] + ' ...'
         return name
 
-    def html_title(self, username='guest'):
-        import cgi
-        name = self.truncated_name()
-        warn = self.warn_about_other_person_editing(username, WARN_THRESHOLD)
-        
-        return template(os.path.join("html", "worksheet", "title.html"),
-                        worksheet = self,
-                        name = cgi.escape(self.truncated_name()),
-                        warn = warn, doc_worksheet = self.is_doc_worksheet(),
-                        username = username)
-
     def is_doc_worksheet(self):
         try:
             return self.__is_doc_worksheet
@@ -2586,7 +2575,7 @@
         return time.time() - self.last_edited()
 
 
-    def warn_about_other_person_editing(self,username, threshold):
+    def warn_about_other_person_editing(self,username, threshold = WARN_THRESHOLD):
         r"""
         Check to see if another user besides username was the last to edit
         this worksheet during the last ``threshold`` seconds.
@@ -2606,7 +2595,8 @@
             if user != username:
                 return True, user
         return False
-        
+
+
     def html_time_since_last_edited(self):
         t = self.time_since_last_edited()
         tm = convert_seconds_to_meaningful_time_span(t)
