changeset 124:41aff926a5ab

Merge in changes from jordi's repo
author dellsystem <ilostwaldo@gmail.com>
date Fri, 14 Sep 2012 22:49:34 -0400
parents 397af252406e (diff) 1abdcf1cf5cb (current diff)
children 8aa8c6dd2b02
files templates/index.djhtml
diffstat 8 files changed, 97 insertions(+), 25 deletions(-) [+]
line wrap: on
line diff
--- a/apps/pygments_style/fixtures/initial_data.json	Thu Sep 13 14:09:31 2012 -0400
+++ b/apps/pygments_style/fixtures/initial_data.json	Fri Sep 14 22:49:34 2012 -0400
@@ -62,5 +62,13 @@
             "class_name": "vibrant",
             "description": null
         }
+    },
+    {
+        "pk": 9,
+        "model": "pygments_style.pygmentsstyle",
+        "fields": {
+            "class_name": "emacs",
+            "description": null
+        }
     }
-]
\ No newline at end of file
+]
--- a/static/css/agora.less	Thu Sep 13 14:09:31 2012 -0400
+++ b/static/css/agora.less	Fri Sep 14 22:49:34 2012 -0400
@@ -75,19 +75,19 @@
             }
         }
 
-        .code {
+        #code-icon {
             .header-icon(-62px);
         }
 
-        .discuss {
+        #discuss-icon {
             .header-icon(-125px);
         }
 
-        .help {
+        #help-icon {
             .header-icon(-209px);
         }
 
-        .about {
+        #about-icon {
             .header-icon(12px);
         }
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/static/css/code/emacs.less	Fri Sep 14 22:49:34 2012 -0400
@@ -0,0 +1,63 @@
+.snippet &.emacs {
+    .hll { background-color: #ffffcc }
+    .c { color: #008800; font-style: italic } /* Comment */
+    .err { border: 1px solid #FF0000 } /* Error */
+    .k { color: #AA22FF; font-weight: bold } /* Keyword */
+    .o { color: #666666 } /* Operator */
+    .cm { color: #008800; font-style: italic } /* Comment.Multiline */
+    .cp { color: #008800 } /* Comment.Preproc */
+    .c1 { color: #008800; font-style: italic } /* Comment.Single */
+    .cs { color: #008800; font-weight: bold } /* 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: #808080 } /* Generic.Output */
+    .gp { color: #000080; 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: #AA22FF; font-weight: bold } /* Keyword.Constant */
+    .kd { color: #AA22FF; font-weight: bold } /* Keyword.Declaration */
+    .kn { color: #AA22FF; font-weight: bold } /* Keyword.Namespace */
+    .kp { color: #AA22FF } /* Keyword.Pseudo */
+    .kr { color: #AA22FF; font-weight: bold } /* Keyword.Reserved */
+    .kt { color: #00BB00; font-weight: bold } /* Keyword.Type */
+    .m { color: #666666 } /* Literal.Number */
+    .s { color: #BB4444 } /* Literal.String */
+    .na { color: #BB4444 } /* Name.Attribute */
+    .nb { color: #AA22FF } /* Name.Builtin */
+    .nc { color: #0000FF } /* Name.Class */
+    .no { color: #880000 } /* Name.Constant */
+    .nd { color: #AA22FF } /* Name.Decorator */
+    .ni { color: #999999; font-weight: bold } /* Name.Entity */
+    .ne { color: #D2413A; font-weight: bold } /* Name.Exception */
+    .nf { color: #00A000 } /* Name.Function */
+    .nl { color: #A0A000 } /* Name.Label */
+    .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */
+    .nt { color: #008000; font-weight: bold } /* Name.Tag */
+    .nv { color: #B8860B } /* Name.Variable */
+    .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
+    .w { color: #bbbbbb } /* Text.Whitespace */
+    .mf { color: #666666 } /* Literal.Number.Float */
+    .mh { color: #666666 } /* Literal.Number.Hex */
+    .mi { color: #666666 } /* Literal.Number.Integer */
+    .mo { color: #666666 } /* Literal.Number.Oct */
+    .sb { color: #BB4444 } /* Literal.String.Backtick */
+    .sc { color: #BB4444 } /* Literal.String.Char */
+    .sd { color: #BB4444; font-style: italic } /* Literal.String.Doc */
+    .s2 { color: #BB4444 } /* Literal.String.Double */
+    .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */
+    .sh { color: #BB4444 } /* Literal.String.Heredoc */
+    .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */
+    .sx { color: #008000 } /* Literal.String.Other */
+    .sr { color: #BB6688 } /* Literal.String.Regex */
+    .s1 { color: #BB4444 } /* Literal.String.Single */
+    .ss { color: #B8860B } /* Literal.String.Symbol */
+    .bp { color: #AA22FF } /* Name.Builtin.Pseudo */
+    .vc { color: #B8860B } /* Name.Variable.Class */
+    .vg { color: #B8860B } /* Name.Variable.Global */
+    .vi { color: #B8860B } /* Name.Variable.Instance */
+    .il { color: #666666 } /* Literal.Number.Integer.Long */
+}
--- a/static/css/imports.less	Thu Sep 13 14:09:31 2012 -0400
+++ b/static/css/imports.less	Fri Sep 14 22:49:34 2012 -0400
@@ -13,3 +13,5 @@
 @import "code/native.less";
 @import "code/vs.less";
 @import "code/monokai.less";
+@import "code/emacs.less";
+
--- a/templates/base.djhtml	Thu Sep 13 14:09:31 2012 -0400
+++ b/templates/base.djhtml	Fri Sep 14 22:49:34 2012 -0400
@@ -38,13 +38,13 @@
     <div id="header">
       <div class="wrap">
         <a href="{% url home %}">
-          <img src="/static/img/logo.png" alt="Agora Octave" class="logo">
+          <img src="/static/img/logo.png" alt="Agora Octave" class="logo" />
         </a>
         <ul class="nav">
-          <li><a href="{% url code %}" class="code">Code</a></li>
-          <li><a href="{% url discuss %}" class="discuss">Discuss</a></li>
-          <li><a href="{% url help %}" class="help">Help</a></li>
-          <li><a href="{% url about %}" class="about">About</a></li>
+          <li><a href="{% url code %}" id="code-icon">Code</a></li>
+          <li><a href="{% url discuss %}" id="discuss-icon">Discuss</a></li>
+          <li><a href="{% url help %}" id="help-icon">Help</a></li>
+          <li><a href="{% url about %}" id="about-icon">About</a></li>
         </ul>
       </div>
     </div>
@@ -101,8 +101,8 @@
       </div>
   </div>
   {% endblock %}
-    <script src="/static/js/jquery.min.js"></script>
-    <script src="/static/js/agora.js"></script>
+    <script src="/static/js/jquery.min.js" type="text/javascript"></script>
+    <script src="/static/js/agora.js" type="text/javascript"></script>
     {% block script_footer %}
     {% endblock %}
   </body>
--- a/templates/index.djhtml	Thu Sep 13 14:09:31 2012 -0400
+++ b/templates/index.djhtml	Fri Sep 14 22:49:34 2012 -0400
@@ -24,7 +24,7 @@
 <div id="info-box" class="row">
     <div class="span3">
         <div class="center-align">
-            <img src="/static/img/browse.png" />
+            <img src="/static/img/browse.png" alt="" />
             <h2>Browse code submissions</h2>
         </div>
         <p>
@@ -34,9 +34,9 @@
             as octave packages. More text to fill up line.
         </p>
     </div><div class="span3">
-        <a href="{%url snippet_new %}">
+        <a href="{% url snippet_new %}">
             <div class="center-align">
-                <img src="/static/img/snippet.png" />
+                <img src="/static/img/snippet.png" alt="" />
                 <h2>Post a snippet</h2>
             </div>
         </a>
@@ -47,7 +47,7 @@
         </p>
     </div><div class="span3">
         <div class="center-align">
-            <img src="/static/img/upload.png" />
+            <img src="/static/img/upload.png" alt="" />
             <h2>Share your code</h2>
         </div>
         <p>
--- a/templates/snippet/snippet_details.djhtml	Thu Sep 13 14:09:31 2012 -0400
+++ b/templates/snippet/snippet_details.djhtml	Fri Sep 14 22:49:34 2012 -0400
@@ -64,7 +64,7 @@
         <select id="change-highlighting"
                 data-default="{{ default_style }}">
             {% for pygments_style in pygments_styles %}
-            <option name="{{ pygments_style }}">
+            <option data-name="{{ pygments_style }}">
                 {{ pygments_style }}
                 {% if pygments_style == default_style %}
                 (default)
@@ -84,7 +84,7 @@
             &mdash;
             Language: {{language}}
         </div>
-    </div>
+    </div><!-- closes .snippet-options -->
     <br />
     <div class="snippet {{ default_style }}">
         <table>
@@ -99,7 +99,7 @@
             </tr>
             {% endfor %}
         </table>
-    </div>
+    </div><!-- closes .snippet -->
 
     <br />
 
@@ -147,7 +147,7 @@
                     {{ tree_item.get_title }}
                 </a>
               {% endifequal %}
-            </div>
+            </div><!-- closes the div surrounding the .diff span -->
             {% for level in structure.closed_levels %}
           </li>
         </ul>
@@ -155,8 +155,8 @@
         {% endfor %}
         <div class="submit">
           <input type="submit" value="{% trans "Compare" %}"/>
-        </div>
-      </div>
+        </div><!-- closes the .submit div -->
+      </div><!-- closes the .tree div -->
     </form>
     {% endif %}
     <br />
@@ -164,8 +164,7 @@
     <a href="{% url snippet_details_raw snippet.secret_id %}">
        {% trans "View raw" %}
      </a>
-</div>
-</div>
+</div><!-- closes the .sidebar div -->
 {% endblock %}
 
 {% block script_footer %}
--- a/templates/snippet/snippet_details.js	Thu Sep 13 14:09:31 2012 -0400
+++ b/templates/snippet/snippet_details.js	Fri Sep 14 22:49:34 2012 -0400
@@ -23,7 +23,7 @@
     */
     var currentStyle = $('#change-highlighting').attr('data-default');
     $('#change-highlighting').change(function () {
-        var newStyle = $(this).find(':selected').attr('name');
+        var newStyle = $(this).find(':selected').attr('data-name');
 
         $('.snippet').removeClass(currentStyle).addClass(newStyle);
         currentStyle = newStyle;