[MKDoc-commit] Lots of i18n and layout updates.

chris at mkdoc.demon.co.uk chris at mkdoc.demon.co.uk
Thu Apr 7 16:44:29 BST 2005


Log Message:
-----------
Lots of i18n and layout updates.

Modified Files:
--------------
    mkd/resources/templates/editor/file:
        en.html

-------------- next part --------------
Index: en.html
===================================================================
RCS file: /var/spool/cvs/mkd/resources/templates/editor/file/en.html,v
retrieving revision 1.8
retrieving revision 1.9
diff -Lresources/templates/editor/file/en.html -Lresources/templates/editor/file/en.html -u -r1.8 -r1.9
--- resources/templates/editor/file/en.html
+++ resources/templates/editor/file/en.html
@@ -1,61 +1,105 @@
 <!--?
 
+  Edit File Component Fragment
+  ============================
+
+  This template is used for the editor interface of a 
+  file component. 
+
+  $Id$
+
+
+  Author: Jean-Michel Hiver, Chris Croome <chris at webarchitects.co.uk>
+  Copyright: (c) 2005, MKDoc Ltd.
+
+  This file is part of MKDoc. 
+  
+  MKDoc is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+  
+  MKDoc is distributed in the hope that it will be useful,
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+  GNU General Public License for more details.
+  
+  You should have received a copy of the GNU General Public License
+  along with MKDoc; if not, write to the Free Software
+  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 
-This template is used for the editor interface of a 
-file component. 
   
 ?-->
 <fieldset
   class="file-component"
   xmlns:petal="http://purl.org/petal/1.0/"
+  xmlns:metal="http://xml.zope.org/namespaces/metal"
+  xmlns:i18n="http://xml.zope.org/namespaces/i18n"
+  i18n:domain="mkdoc"
   petal:define="name_title       string:${self/block_name}_title;
                 name_move_up     string:${self/block_name}_up;
                 name_move_down   string:${self/block_name}_down;
                 name_delete      string:${self/block_name}_delete;
                 name_upload      string:${self/block_name}_upload;
-                name_file        string:${self/block_name}_file;
+                name_file        string:${self/block_name}_file;"
+  ondblclick="window.location='./#component-${self/name_noext}'"
+>
+
+<!--?
                 align            self/align;
                 align_opposite   self/align_opposite;
                 dir              self/direction"
-  ondblclick="window.location='./#component-${self/name_noext}'"
->
+-->
 
-  <legend
-    xml:lang="en"
-    lang="en"
-    dir="ltr"
-    petal:attributes="align align"
-  ><a 
-     name="component-${self/name_noext}" 
-     id="component-${self/name_noext}"
-  >File component</a></legend>
+  <legend>
+    <a 
+      xml:lang="en"
+      lang="en"
+      dir="ltr"
+      name="component-${self/name_noext}" 
+      id="component-${self/name_noext}"
+      i18n:attributes="xml:lang two-letter-language-code;
+                       lang     two-letter-language-code;
+                       dir      text-direction;"
+      i18n:translate="file-component"
+    >File component</a>
+  </legend>
 
   <div
-    petal:condition="self/has_errors"
+    petal:condition="true: self/has_errors"
     petal:repeat="error self/errors"
   >
     <p
-      xml:lang="en" lang="en" dir="ltr" class="error"
+      xml:lang="en" 
+      lang="en" 
+      dir="ltr" 
+      class="error"
+      i18n:attributes="xml:lang two-letter-language-code;
+                       lang     two-letter-language-code;
+                       dir      text-direction;"
+      i18n:translate="no-file-has-been-uploaded"
       petal:condition="error/is --component/file/no_file"
-    >No file has been uploaded. Please upload a file.</p>
+    >
+      No file has been uploaded. Please upload a file.
+    </p>
     <p
-      xml:lang="en" lang="en" dir="ltr" class="error"
+      xml:lang="en" 
+      lang="en" 
+      dir="ltr" 
+      class="error"
+      i18n:attributes="xml:lang two-letter-language-code;
+                       lang     two-letter-language-code;
+                       dir      text-direction;"
+      i18n:translate="provide-a-title-for-this-file"
       petal:condition="error/is --component/file/title_empty"
-    >The title field is empty.</p>
+    >
+      Please provide a title for this file. 
+    </p>
   </div>
 
     <p
       class="up"
     >
-      <label
-        for="file_up"
-        xml:lang="en"
-        lang="en"
-        dir="ltr"
-        petal:attributes="for name_move_up"
-      >
-        Move component 
-      </label>
 
       <input
         type="submit"
@@ -66,7 +110,30 @@
         lang="en"
         dir="ltr"
         title="Move this component up."
-        petal:attributes="name name_move_up; id name_move_up"
+        petal:attributes="name name_move_up; 
+                          id   name_move_up"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    move-component-up;
+                         value    up;"
+      />
+      <input
+        type="submit"
+        name="file_down"
+        id="file_down"
+        value="Down"
+        xml:lang="en"
+        lang="en"
+        dir="ltr"
+        title="Move this component down."
+        petal:attributes="name name_move_down; 
+                          id   name_move_down"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    move-component-down;
+                         value    Down;"
       />
 
     </p>
@@ -83,75 +150,103 @@
         lang="en"
         dir="ltr"
         petal:condition="false:self/file"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;"
+        i18n:translate="no-file-has-been-uploaded"
       >No file has been uploaded yet.</span>
     </p>
 
-    <p>
+    <p
+      class="field"
+    >
+      <label
+        for="file_title"
+        xml:lang="en"
+        lang="en"
+        dir="ltr"
+        petal:attributes="for name_title"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;"
+        i18n:translate="title"
+      >Title</label>
       <em
         class="help"
         xml:lang="en"
         lang="en"
         dir="ltr"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;"
+        i18n:translate="file-title-help"
       >
         The title of the file. It is often appropriate to say what format the file
         is in, for example, 'My essay (MS Word document)'.
       </em>
-      <label
-        for="file_title"
-        xml:lang="en"
-        lang="en"
-        dir="ltr"
-        title="The title of the file attachment."
-        petal:attributes="for name_title"
-      >Title</label>
-      <br />
       <input
         type="text"
         name="file_title"
         id="file_title"
         class="input-text"
         value="File Title"
-        size="60"
+        size="35"
         title="Enter the title of the file here."
-        petal:attributes="name name_title; id name_title; value self/title"
+        petal:attributes="name  name_title; 
+                          id    name_title; 
+                          value self/title"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    enter-file-title-here;"
       />
 
     </p>
 
-    <p>
+    <p
+      class="field"
+    >
+      <label
+        for="file"
+        xml:lang="en"
+        lang="en"
+        dir="ltr"
+        petal:attributes="for self/block_name"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;"
+        i18n:translate="select-and-upload"
+      >
+        Select and upload 
+      </label>
       <em
         class="help"
         xml:lang="en"
         lang="en"
         dir="ltr"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;"
+        i18n:translate="file-upload-help"
       >
-         Use the Browse button to select the file from your computer and the Upload 
+         Use the Browse button to select the file from your computer and the 
+         <span
+           xml:lang="en"
+           lang="en"
+           dir="ltr"
+           i18n:translate="file-upload-help"
+           i18n:name="upload"
+         >Upload </span>
          button to upload it. 
       </em>
-      <span
-        xml:lang="en"
-        lang="en"
-        dir="ltr"
-        >
-        <label
-          for="file"
-          title="Select the file."
-          petal:attributes="for self/block_name"
-        >Select</label>
-        and
-        <label
-          for="file_upload"
-          title="Upload the file."
-          petal:attributes="for name_upload"
-        >upload file</label>
-      </span>
-      <br />
       <input
         type="hidden"
         name="block_name_file"
         id="block_name_file"
         value="file"
-        petal:attributes="name name_file; id name_file; value self/file"
+        petal:attributes="name  name_file; 
+                          id    name_file; 
+                          value self/file"
       />
       <input
         type="file"
@@ -162,7 +257,12 @@
         lang="en"
         dir="ltr"
         title="Select the file you want to upload."
-        petal:attributes="name self/block_name; id self/block_name"
+        petal:attributes="name self/block_name; 
+                          id   self/block_name"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    select-the-file-to-upload;"
       />
       <input
         type="submit"
@@ -172,37 +272,36 @@
         xml:lang="en"
         lang="en"
         dir="ltr"
-        title="Upload the selected Image."
-        petal:attributes="name name_upload; id name_upload"
+        title="Upload the selected file."
+        petal:attributes="name name_upload; 
+                          id   name_upload"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         value    upload;
+                         title    upload-selected-file;"
       />
 
     </p>
 
-    <p>
-      <input
-        type="submit"
-        name="file_delete"
-        id="file_delete"
-        value="Delete Component"
-        xml:lang="en"
-        lang="en"
-        dir="ltr"
-        title="Delete this component."
-        petal:attributes="name name_delete; id name_delete"
-      />
-      <bdo
-        dir="ltr"
-        petal:atributes="dir self/direction"
-        petal:condition="self/is_saved"
-      >|</bdo>
+    <p
+      class="down"
+    >
+
       <a 
         href="#" 
         xml:lang="en"
         lang="en"
         dir="ltr"
+        title="Copy this component to another document."
         petal:attributes="href string:${self/mkdoc_uri},copy"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    copy-to-another-document;"
+        i18n:translate="copy-elsewhere"
         petal:condition="self/is_saved"
-      >Copy to another document</a>
+      >Copy elsewhere</a>
       <bdo
         dir="ltr"
         petal:atributes="dir self/direction"
@@ -213,33 +312,36 @@
         xml:lang="en"
         lang="en"
         dir="ltr"
+        title="Move this component to another document."
         petal:attributes="href string:${self/mkdoc_uri},move"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         title    move-to-another-document;"
+        i18n:translate="move-elsewhere"
         petal:condition="self/is_saved"
-      >Move to another document</a>
-    </p>
-
-    <p
-      class="down"
-    >
-      <label
-        for="file_down"
-        xml:lang="en"
-        lang="en"
+      >Move elsewhere</a>
+      <bdo
         dir="ltr"
-        petal:attributes="for name_move_down"
-      >
-        Move component
-      </label>
+        petal:atributes="dir self/direction"
+        petal:condition="self/is_saved"
+      >|</bdo>
       <input
         type="submit"
-        name="file_down"
-        id="file_down"
-        value="Down"
+        name="file_delete"
+        id="file_delete"
+        value="Delete"
         xml:lang="en"
         lang="en"
         dir="ltr"
-        title="Move this component down."
-        petal:attributes="name name_move_down; id name_move_down"
+        title="Delete this component."
+        petal:attributes="name name_delete; 
+                          id   name_delete"
+        i18n:attributes="xml:lang two-letter-language-code;
+                         lang     two-letter-language-code;
+                         dir      text-direction;
+                         value    delete;
+                         title    delete-component;"
       />
     </p>
 


More information about the MKDoc-commit mailing list