[LON-CAPA-cvs] cvs: loncom / Makefile loncapa_apache.conf /build help_graphics_converter.pl /html/adm/help/png authorRemote.png constructionSpace.png constructionSpaceForPublishing.png creatingANewCourse.png creatingNewProblemResource.png formulaResponse.png login.png mapAdvancedEditorNew.png mapClickedStart.png mapEditFirstClick.png mapEditInitial.png mapEditingButton.png mapEditorDirectoryBrowser.png mapEditorResourceChosen.png mapEditorSelection.png mapInsertResource.png mapNewResource.png mapSecondWindowSecondResource.png mapSimpleEditor.png mapStraightened.png mapTwoResources.png numericalResponse1.png numericalResponseEditor.png numericalResponseSlopeProblem.png numericalResponseVarInText.png optionResponseEditing.png optionResponseProblem.png publishMetadata.png radioResponse2.png radioResponseHint.png smallHelp.png stringResponseEditor.png studentInterface.png /html/adm/help/tex About_Authors_Manual.tex About_Numerical_and_Formula_Response.tex Author_LON-CAPA_Introduction.tex Author_Manual_Title_Page.tex Author_Numerical_and_Formula.tex Author_Remote_Control.tex Calling_Functions.tex Construction_Space_Overview.tex Creating_A_Course_Intro.tex Creating_New_Content_Pages.tex Creating_Online_Problems.tex Creating_Radio_Response_Problems.tex Foils.tex Formula_Response_Example.tex Formula_Response_Limitations.tex Formula_Response_Problems.tex Formula_Response_Sampling.tex Formula_Tolerance.tex How_To_Edit_Existing_Content_Pages.tex Latex_Footer.tex Latex_Header.tex Login_To_LON-CAPA.tex Metadata_Description.tex Numerical_Response_Advanced_Example.tex Numerical_Response_Format.tex Numerical_Response_Intro.tex Numerical_Response_Introduction.tex Numerical_Response_Parts_A.tex Numerical_Response_Parts_B.tex Numerical_Response_Problems.tex Numerical_Response_Randomization.tex Numerical_Response_Simple_Example.tex Numerical_Response_Tutorial_A.tex Numerical_Response_Units.tex Option_Response_Concept_Group_Example.tex Option_Response_Matching_Example.tex Option_Response_Problem_Creation.tex Option_Response_Problem_Fig

bowersj2 lon-capa-cvs@mail.lon-capa.org
Fri, 05 Jul 2002 16:12:32 -0000


This is a MIME encoded message

--bowersj21025885552
Content-Type: text/plain

bowersj2		Fri Jul  5 12:12:32 2002 EDT

  Added files:                 
    /doc/help	README author.manual.texxml latexSplitter.py 
             	rebuildLabelHash.pl simpleEdit.py texxml2latex.pl 
    /loncom/build	help_graphics_converter.pl 
    /loncom/html/adm/help/png	authorRemote.png constructionSpace.png 
                             	constructionSpaceForPublishing.png 
                             	creatingANewCourse.png 
                             	creatingNewProblemResource.png 
                             	formulaResponse.png login.png 
                             	mapAdvancedEditorNew.png 
                             	mapClickedStart.png mapEditFirstClick.png 
                             	mapEditInitial.png mapEditingButton.png 
                             	mapEditorDirectoryBrowser.png 
                             	mapEditorResourceChosen.png 
                             	mapEditorSelection.png 
                             	mapInsertResource.png mapNewResource.png 
                             	mapSecondWindowSecondResource.png 
                             	mapSimpleEditor.png mapStraightened.png 
                             	mapTwoResources.png 
                             	numericalResponse1.png 
                             	numericalResponseEditor.png 
                             	numericalResponseSlopeProblem.png 
                             	numericalResponseVarInText.png 
                             	optionResponseEditing.png 
                             	optionResponseProblem.png 
                             	publishMetadata.png radioResponse2.png 
                             	radioResponseHint.png smallHelp.png 
                             	stringResponseEditor.png 
                             	studentInterface.png 
    /loncom/html/adm/help/tex	About_Authors_Manual.tex 
                             	About_Numerical_and_Formula_Response.tex 
                             	Author_LON-CAPA_Introduction.tex 
                             	Author_Manual_Title_Page.tex 
                             	Author_Numerical_and_Formula.tex 
                             	Author_Remote_Control.tex 
                             	Calling_Functions.tex 
                             	Construction_Space_Overview.tex 
                             	Creating_A_Course_Intro.tex 
                             	Creating_New_Content_Pages.tex 
                             	Creating_Online_Problems.tex 
                             	Creating_Radio_Response_Problems.tex 
                             	Foils.tex Formula_Response_Example.tex 
                             	Formula_Response_Limitations.tex 
                             	Formula_Response_Problems.tex 
                             	Formula_Response_Sampling.tex 
                             	Formula_Tolerance.tex 
                             	How_To_Edit_Existing_Content_Pages.tex 
                             	Latex_Footer.tex Latex_Header.tex 
                             	Login_To_LON-CAPA.tex 
                             	Metadata_Description.tex 
                             	Numerical_Response_Advanced_Example.tex 
                             	Numerical_Response_Format.tex 
                             	Numerical_Response_Intro.tex 
                             	Numerical_Response_Introduction.tex 
                             	Numerical_Response_Parts_A.tex 
                             	Numerical_Response_Parts_B.tex 
                             	Numerical_Response_Problems.tex 
                             	Numerical_Response_Randomization.tex 
                             	Numerical_Response_Simple_Example.tex 
                             	Numerical_Response_Tutorial_A.tex 
                             	Numerical_Response_Units.tex 
                             	Option_Response_Concept_Group_Example.tex 
                             	Option_Response_Matching_Example.tex 
                             	Option_Response_Problem_Creation.tex 
                             	Option_Response_Problem_Figure.tex 
                             	Option_Response_Problem_Parts.tex 
                             	Option_Response_Problems.tex 
                             	Option_Response_Simple.tex 
                             	Problem_Editor_Testing_Area.tex 
                             	Problem_Types.tex 
                             	Publishing_A_Resource.tex 
                             	Publishing_Author_Tutorial_Segue.tex 
                             	Publishing_Intro.tex 
                             	Radio_Response_Problems.tex 
                             	Radio_Response_Randomization.tex 
                             	Resource_Types.tex 
                             	Script_Tutorial_Intro.tex 
                             	Scripting_Help.tex 
                             	Sequence_Advanced_Editor_Creation.tex 
                             	Sequence_Definition.tex 
                             	Sequence_Editor_Selection.tex 
                             	Sequence_Page_Maps.tex 
                             	Sequence_Simple_Editor_Creation.tex 
                             	Sequence_Top-Level.tex 
                             	Significant_Figures.tex 
                             	String_Response_Problem_Creation.tex 
                             	String_Response_Problems.tex 
                             	Tolerance.tex 
                             	Variable_Naming_Conventions.tex 
                             	Variable_Tutorial_A.tex 
                             	Variables_in_Scripts.tex 
                             	Variables_in_the_Answer_Block.tex 
                             	Variables_in_the_Text_Block.tex 
    /loncom/interface	lonhelp.pm 

  Removed files:               
    /doc	adding_a_author.txt creating_a_course.txt creating_a_user.txt 
        	how_to_domain_coordinator.txt mysql_note.txt mysql_note_2.txt 
        	security.html security.txt 

  Modified files:              
    /doc/loncapafiles	loncapafiles.lpml 
    /doc/tutorial	tutorial.lyx 
    /loncom	Makefile loncapa_apache.conf 
    /loncom/interface	loncommon.pm 
  Log:
  This commit implements the .tex-based online help system in LON-CAPA. It
  may be necessary to manually run loncom/build/help_graphics_converter.pl
  and doc/help/rebuildLabelHash.pl after a cvs update, and
  loncapa_apache.conf may need to be manually copied to /etc. (The
  loncapafiles.lpml has been updated.)
  
  After merging this, the URL http://[loncapahost]/adm/help/Foils.hlp
  should display a help file.
  
  Also, some *very* out-of-date files have been removed from the /doc
  directory.
  
  
  
--bowersj21025885552
Content-Type: text/plain
Content-Disposition: attachment; filename="bowersj2-20020705121232.txt"

Index: doc/loncapafiles/loncapafiles.lpml
diff -u doc/loncapafiles/loncapafiles.lpml:1.135 doc/loncapafiles/loncapafiles.lpml:1.136
--- doc/loncapafiles/loncapafiles.lpml:1.135	Mon Jun 24 16:18:34 2002
+++ doc/loncapafiles/loncapafiles.lpml	Fri Jul  5 12:12:30 2002
@@ -3,7 +3,7 @@
 <!-- loncapafiles.lpml -->
 <!-- Scott Harrison -->
 
-<!-- $Id: loncapafiles.lpml,v 1.135 2002/06/24 20:18:34 matthew Exp $ -->
+<!-- $Id: loncapafiles.lpml,v 1.136 2002/07/05 16:12:30 bowersj2 Exp $ -->
 
 <!--
 
@@ -413,6 +413,10 @@
   <targetdir dist='default'>home/httpd/html/adm/help</targetdir>
   <categoryname>server readonly</categoryname>
   <description>online help documentation</description>
+  <build trigger='always run'>
+    perl loncom/build/help_graphics_converter.pl
+    perl doc/help/rebuildLabelHash.pl
+  </build>
 </directory>
 <directory dist='default'>
   <targetdir dist='default'>home/httpd/html/adm/help/lib/perl</targetdir>
Index: doc/tutorial/tutorial.lyx
diff -u doc/tutorial/tutorial.lyx:1.7 doc/tutorial/tutorial.lyx:1.8
--- doc/tutorial/tutorial.lyx:1.7	Fri Jun 14 16:28:52 2002
+++ doc/tutorial/tutorial.lyx	Fri Jul  5 12:12:31 2002
@@ -1,5 +1,5 @@
-#LyX 1.1 created this file. For more info see http://www.lyx.org/
-\lyxformat 218
+#LyX 1.2 created this file. For more info see http://www.lyx.org/
+\lyxformat 220
 \textclass article
 \begin_preamble
 \usepackage{floatflt}
@@ -14,6 +14,8 @@
 \paperpackage a4
 \use_geometry 1
 \use_amsmath 0
+\use_natbib 0
+\use_numerical_citations 0
 \paperorientation portrait
 \leftmargin 1in
 \topmargin 1.25in
@@ -179,15 +181,23 @@
 
 .
  
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 297 234
-file login.eps
-width 3 50
-flags 11
-
+\begin_inset Graphics FormatVersion 1
+	filename login.eps
+	display color
+	size_type 1
+	width 50page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 297pt
+	lyxheight 234pt
 \end_inset 
 
 
@@ -199,7 +209,9 @@
 \end_inset 
 
 LON-CAPA Log in screen 
-\end_float 
+\end_inset 
+
+
 \layout Standard
 
 Fill in the Username and Password boxes with your information.
@@ -218,171 +230,6 @@
 \end_inset 
 
 Author Remote Control
-\layout Comment
-
-Comment on the remote controls: I'll only mention this once, but imagine
- this comment exists everywhere a remote control image is used.
- The whole 
-\begin_inset Quotes eld
-\end_inset 
-
-remote control
-\begin_inset Quotes erd
-\end_inset 
-
- metaphor is fundamentally flawed and probably can't be salvaged.
- Why is it flawed?
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-1.
- The remote control invokes a metaphor, that of remote controls.
- However, remote controls are useful in the real world, despite the overwhelming
- complexity of modern remotes, for three major reasons: One, they never,
- ever, ever change.
- Two, they provide immense amounts of tactile feedback, allowing one to
- overcome the complexity of using one by putting the knowledge into motor
- memory.
- (There are equivalent usability principles in usability, as well; look
- up Fitt's Law, for instance.) Three, they all basically do the same thing;
- pick up an unfamiliar TV control and you at least know in advance there
- will be numbers for channel changing, vol up and down, chan up and down,
- mute, etc.
- The remotes used in this system do not have any of these properties.
- Remotes are actually horrid UI, because they are very, very difficult to
- learn; they make up for it by being useful and persistent.
-\layout Comment
-
-Further, remotes should *do* things.
- This remote is like a remote that no matter what button you push, it invokes
- a menu.
- Most remotes have 
-\series bold 
-one
-\series default 
- explicit 
-\begin_inset Quotes eld
-\end_inset 
-
-menu
-\begin_inset Quotes erd
-\end_inset 
-
- button to invoke a menu that has all the feature that aren't worth valuable
- remote control space.
-\layout Comment
-
-In fact, the metaphor is so unsuccessful that any moderately savvy Internet
- user will almost immediately come to conceptualize the remote as just another
- list of links, albeit a clumsy and inconvenient one.
- Why not give them that in the first place?
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-2.
- Even the simplest 
-\begin_inset Quotes eld
-\end_inset 
-
-remote
-\begin_inset Quotes erd
-\end_inset 
-
- I see in the tutorial has eight buttons, which nearly immediately becomes
- seventeen (!) buttons, all incomprehensible, and I didn't get a chance
- to count during the interview, but I saw a remote flash by (student remote?
- admin remote? that wouldn't matter as much) that had at least twenty, probably
- 24 buttons, again, all or nearly all incomprehensible.
- This is needlessly intimidating.
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-3.
- By committing to this 
-\begin_inset Quotes eld
-\end_inset 
-
-remote control
-\begin_inset Quotes erd
-\end_inset 
-
- layout, you commit to a remote control's layout limitations, except that
- an actual remote control can get away with a 6pt or smaller font, or weird
- specialized symbols, or whatnot.
- I'm looking at a (real) remote control right now that manages to get 
-\begin_inset Quotes eld
-\end_inset 
-
-channel return
-\begin_inset Quotes erd
-\end_inset 
-
- onto one button.
- That whole phrase fits *twice* into the space the 
-\begin_inset Quotes eld
-\end_inset 
-
-ROLES
-\begin_inset Quotes erd
-\end_inset 
-
- button takes up on my printout! So in actuality, you're committing to something
- no sane remote control designer could deal with.
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-4.
- Requiring the user to mouse over something to see what it does is not a
- solution.
- Limiting yourself to an 8 by 2 array of characters to explain yourself
- compounds the problem even more.
- (Another over-literal extension of the remote control metaphor.) Also, as
- you may have observed, the accessibility of this is nil.
- 
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-The upshot is that the only upside to the remote control is a moderately
- pleasing graphic; the downsides are pretty much everything, up to and including
- possible illegality under accessibility laws.
- Unfortunately, I do not see any way to salvage any aspect of the remote
- control; it's going to suck until it's replaced.
- Pleasing graphics are relatively easy to come by nowadays; it should not
- drive the design.
- I'll admit (freely!) I'm not a graphics designer...
- graphics designers aren't web developers (designers), either.
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-We're data-mining the web logs to see what people actually use.
- This is good.
- We may need to do some really simple stuff before he finishes.
- Raw statistics on what buttons are pressed most often can probably be interpret
-ed easily enough for our purposes.
- No matter what the final design is, it should emphasize the two or three
- commands used day in and day out, as determined by empirical analysis,
- and shuffle the other commands onto another sub menu or sub menus.
- Then, use the additional space you'll have (even if you keep the same size
- window) and actually *spell out* the options.
- 
 \layout Standard
 
 The Author Remote Control, show in figure 
@@ -397,15 +244,23 @@
  The Remote Control is a tool that allows you to switch between functions
  and roles within LON-CAPA.
  
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 180 420
-file authorRemote.eps
-height 3 50
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename authorRemote.eps
+	display color
+	size_type 1
+	height 50page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 180pt
+	lyxheight 420pt
 \end_inset 
 
 
@@ -417,13 +272,9 @@
 \end_inset 
 
 
-\end_float 
-\layout Comment
+\end_inset 
+
 
-Of the eight choices on this menu, only two (ROLES and LOGOUT) make *any*
- sort of sense on a first glance.
- Abbreviations are evil in this sort of application and should be used as
- a truly last resort.
 \layout Standard
 
 When you move your mouse over the buttons in the remote, the sixteen gray
@@ -608,15 +459,24 @@
 Description of the Construction Space
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 42
-file constructionSpace.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename constructionSpace.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 42pt
 \end_inset 
 
 
@@ -635,12 +495,12 @@
 
 
 \begin_inset  Tabular
-<lyxtabular version="2" rows="10" columns="2">
-<features rotate="false" islongtable="false" endhead="0" endfirsthead="0" endfoot="0" endlastfoot="0">
-<column alignment="center" valignment="top" leftline="true" rightline="false" width="" special="">
-<column alignment="left" valignment="top" leftline="true" rightline="true" width="5in" special="">
-<row topline="true" bottomline="true" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<lyxtabular version="3" rows="10" columns="2">
+<features>
+<column alignment="center" valignment="top" leftline="true" width="0pt">
+<column alignment="left" valignment="top" leftline="true" rightline="true" width="5in">
+<row topline="true" bottomline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -650,7 +510,7 @@
 Button Name
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="left" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -661,8 +521,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -670,7 +530,7 @@
 Publish this Resource
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -679,8 +539,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -688,7 +548,7 @@
 List Directory
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -697,8 +557,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -706,7 +566,7 @@
 Copy
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -715,8 +575,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -724,7 +584,7 @@
 Browse
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -733,8 +593,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -742,7 +602,7 @@
 Upload File
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -751,8 +611,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -760,7 +620,7 @@
 Retrieve Old Version
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -769,8 +629,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -778,7 +638,7 @@
 Delete
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -787,8 +647,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="false" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -796,7 +656,7 @@
 Rename
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -805,8 +665,8 @@
 \end_inset 
 </cell>
 </row>
-<row topline="true" bottomline="true" newpage="false">
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="false" rotate="false" usebox="none" width="" special="">
+<row topline="true" bottomline="true">
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -814,7 +674,7 @@
 New Subdirectory
 \end_inset 
 </cell>
-<cell multicolumn="0" alignment="center" valignment="top" topline="true" bottomline="false" leftline="true" rightline="true" rotate="false" usebox="none" width="" special="">
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
 \begin_inset Text
 
 \layout Standard
@@ -828,7 +688,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 The Construction Space, as seen in figure 
 \begin_inset LatexCommand \ref{Construction Space Figure}
 
@@ -935,7 +796,9 @@
 
 If you're following this as a tutorial, create at least one content page,
  which we'll use later as raw material.
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Visit the FAQ at 
@@ -951,7 +814,9 @@
 \end_inset 
 
  warnings.
-\end_float 
+\end_inset 
+
+
 \layout Subsection
 
 How to Edit Existing Content Pages
@@ -1203,7 +1068,7 @@
 \series default 
  problems ask the student to type in a math formula for the answer.
  If the answer is 
-\begin_inset Formula \( x^{2}-11 \)
+\begin_inset Formula $x^{2}-11$
 \end_inset 
 
 , the student can enter "x^2 - 11", "x*x - 11", "x^2 + 21 - 10", etc.
@@ -1214,15 +1079,24 @@
 Creating Radio Response Problems
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 202
-file creatingNewProblemResource.eps
-width 3 80
-flags 13
-
+\begin_inset Graphics FormatVersion 1
+	filename creatingNewProblemResource.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 202pt
 \end_inset 
 
 
@@ -1234,7 +1108,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 To create a Radio Response
 \begin_inset LatexCommand \index{Radio Response}
 
@@ -1269,15 +1144,23 @@
 \end_inset 
 
 .
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 283
-file radioResponse2.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename radioResponse2.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 283pt
 \end_inset 
 
 
@@ -1289,7 +1172,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  You will need to specify the question text and foil statements.
 \layout Enumerate
 
@@ -1428,15 +1312,24 @@
 .
 \layout Enumerate
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 92
-file radioResponseHint.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename radioResponseHint.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 92pt
 \end_inset 
 
 
@@ -1448,7 +1341,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 Scroll down to the Hint element, as shown in Figure 
 \begin_inset LatexCommand \ref{Radio Response Hint Element Figure}
 
@@ -1553,15 +1447,24 @@
 Option Response problems with Concept Groups
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 134
-file optionResponseProblem.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename optionResponseProblem.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 134pt
 \end_inset 
 
 
@@ -1573,7 +1476,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 Each Option Response problem can have three parts:
 \layout Enumerate
 
@@ -1688,35 +1592,51 @@
 \end_inset 
 
 , Ballade
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Debussy.
-\end_float 
+\end_inset 
+
+
 \layout Itemize
 
 The Pastoral Symphony, The Ninth Symphony
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Beethoven.
-\end_float 
+\end_inset 
+
+
 \layout Itemize
 
 Sleeping Beauty Suite, The Dance of the Sugar Plum Fairies
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Tchaikovsky.
-\end_float 
+\end_inset 
+
+
 \layout Itemize
 
 Slavonic Dances, New World Symphony
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Dvorak.
-\end_float 
+\end_inset 
+
+
 \layout Standard
 
 You could then add the following options to the option list:
@@ -1812,15 +1732,23 @@
 Edit
 \series default 
  button above the sample problem to enter edit mode.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 276
-file optionResponseEditing.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename optionResponseEditing.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 276pt
 \end_inset 
 
 
@@ -1832,7 +1760,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  You should see the Option Response page open up, which should look something
  like what you see in figure 
 \begin_inset LatexCommand \ref{Option Response Editor Figure}
@@ -1934,7 +1863,9 @@
 
 Make sure all the options you want to delete are not used for any of your
  foils
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 If a deleted option is used in a foil, it will appear in a text box in the
@@ -1954,7 +1885,8 @@
 \series default 
 .
  A drop-down box will reappear.
-\end_float 
+\end_inset 
+
 .
  To delete the irrelevant options from the Option Response question, select
  that option from the 
@@ -2042,15 +1974,23 @@
 Edit
 \series default 
  button above the sample problem to enter edit mode.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 320
-file stringResponseEditor.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename stringResponseEditor.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 320pt
 \end_inset 
 
 
@@ -2062,7 +2002,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  You should see the String Response editor page open up, which should look
  something like what you see in figure 
 \begin_inset LatexCommand \ref{String Response Editor Figure}
@@ -2106,8 +2047,9 @@
 .
  For example, this is useful in chemistry, where HO and Ho are completely
  different answers
-\begin_float footnote 
-\end_deeper 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 
@@ -2120,10 +2062,10 @@
 Ho
 \series default 
  is the element 67, Holmium, in the Lanthanides.
-\end_float 
+\end_inset 
+
 .
  The student must match the case of the answer.
-\begin_deeper 
 \layout Enumerate
 
 
@@ -2299,27 +2241,27 @@
 Numerical Response problems are answered by entering a number and an optional
  unit.
  For instance, a numerical response problem might have an answer of 
-\begin_inset Formula \( 2m/s^{2} \)
+\begin_inset Formula $2m/s^{2}$
 \end_inset 
 
 .
  Formula Response problems are answered by entering a mathematical formula.
  For instance, a numerical response problem might have an answer of 
-\begin_inset Formula \( x^{2}+11 \)
+\begin_inset Formula $x^{2}+11$
 \end_inset 
 
 .
  The answer may be in any equivalent format.
  For instance, for 
-\begin_inset Formula \( x^{2}+11 \)
+\begin_inset Formula $x^{2}+11$
 \end_inset 
 
 , the system will also accept 
-\begin_inset Formula \( x*x+11 \)
+\begin_inset Formula $x*x+11$
 \end_inset 
 
  or 
-\begin_inset Formula \( x^{2}+21-10 \)
+\begin_inset Formula $x^{2}+21-10$
 \end_inset 
 
 .
@@ -2410,15 +2352,24 @@
 
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 168
-file constructionSpaceForPublishing.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename constructionSpaceForPublishing.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 168pt
 \end_inset 
 
 
@@ -2430,7 +2381,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 To publish a resource, log in and choose your role to be an Author.
  Then click 
 \series bold 
@@ -2448,15 +2400,23 @@
 Publish
 \series default 
  button for the resource you wish to publish.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 338
-file publishMetadata.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename publishMetadata.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 338pt
 \end_inset 
 
 
@@ -2468,7 +2428,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  You'll get a metadata screen that should look something like figure 
 \begin_inset LatexCommand \ref{Publishing Metadata Screen Figure}
 
@@ -2549,9 +2510,6 @@
 \series default 
  drop-down.
  This setting controls who is allowed to use your resource as follows:
-\layout Comment
-
-Is this right?
 \layout Itemize
 
 
@@ -2637,15 +2595,24 @@
  
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 238 83
-file mapEditorSelection.eps
-width 3 40
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapEditorSelection.eps
+	display color
+	size_type 1
+	width 40page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 238pt
+	lyxheight 83pt
 \end_inset 
 
 
@@ -2657,7 +2624,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 To create a Sequence resource, create a new resource as described in section
  
 \begin_inset LatexCommand \ref{Creating New Content Pages}
@@ -2702,15 +2670,24 @@
 Creating a Simple .sequence With The Simple Editor
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 250
-file mapSimpleEditor.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapSimpleEditor.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 250pt
 \end_inset 
 
 
@@ -2722,7 +2699,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 After creating a new .sequence resource and getting the editor selection
  prompt (figure 
 \begin_inset LatexCommand \ref{Map Editor Selection Figure}
@@ -2804,15 +2782,23 @@
 \series default 
  button to get to the advanced map editor.
  
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 205
-file mapAdvancedEditorNew.eps
-width 3 80
-flags 11
-
+\begin_inset Graphics FormatVersion 1
+	filename mapAdvancedEditorNew.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 205pt
 \end_inset 
 
 
@@ -2824,7 +2810,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 You should see the initial map editor as shown in figure 
 \begin_inset LatexCommand \ref{Initial Map Editor FIgure}
 
@@ -2835,15 +2822,24 @@
  window which will contain information as you add resources.
 \layout Enumerate
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 221
-file mapClickedStart.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapClickedStart.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 221pt
 \end_inset 
 
 
@@ -2859,7 +2855,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 Click the 
 \series bold 
 Start
@@ -2880,15 +2877,23 @@
 Finish
 \series default 
  box.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 70 210
-file mapStraightened.eps
-height 3 25
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapStraightened.eps
+	display color
+	size_type 1
+	height 25page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 70pt
+	lyxheight 210pt
 \end_inset 
 
 
@@ -2900,7 +2905,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  After that, click 
 \series bold 
 Straighten
@@ -2915,15 +2921,24 @@
  This creates a simple map that flows from beginning to end.
 \layout Enumerate
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 271 252
-file mapInsertResource.eps
-height 3 30
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapInsertResource.eps
+	display color
+	size_type 1
+	height 30page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 271pt
+	lyxheight 252pt
 \end_inset 
 
 
@@ -2935,7 +2950,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 To insert a resource into the flow, click the black line with two arrows,
  seen between the 
 \series bold 
@@ -2979,15 +2995,23 @@
 Network Directory Browser
 \series default 
  will appear,
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 357 162
-file mapEditorDirectoryBrowser.eps
-width 3 60
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapEditorDirectoryBrowser.eps
+	display color
+	size_type 1
+	width 60page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 357pt
+	lyxheight 162pt
 \end_inset 
 
 
@@ -2999,7 +3023,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  looking something like figure 
 \begin_inset LatexCommand \ref{Map Editor Network Directory Browser Figure}
 
@@ -3012,15 +3037,23 @@
 \series default 
  button that is next to the resource you want to place in the chosen resource
  box.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 42 252
-file mapEditorResourceChosen.eps
-height 3 30
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename mapEditorResourceChosen.eps
+	display color
+	size_type 1
+	height 30page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 42pt
+	lyxheight 252pt
 \end_inset 
 
 
@@ -3032,7 +3065,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  Once you've done that, if you look back at the window that popped up when
  you clicked on 
 \series bold 
@@ -3132,15 +3166,23 @@
 course
 \series default 
 .
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 238 231
-file creatingANewCourse.eps
-width 3 40
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename creatingANewCourse.eps
+	display color
+	size_type 1
+	width 40page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 238pt
+	lyxheight 231pt
 \end_inset 
 
 
@@ -3152,7 +3194,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  Courses have a Top-level Map which defines the whole course.
  This top-level map will often itself contain maps corresponding to homework
  assignments, chapters, or units.
@@ -3207,15 +3250,24 @@
 The Parts of a Numerical Response Problem
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 356
-file numericalResponse1.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename numericalResponse1.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 356pt
 \end_inset 
 
 
@@ -3227,7 +3279,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 A Numerical Response problem has seven major parts by default, as seen in
  figure 
 \begin_inset LatexCommand \ref{Numerical Response Editor Figure}
@@ -3299,12 +3352,14 @@
  answer to be in order to count it correct.
  For technical reasons, it is almost never a good idea to set this parameter
  to zero
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 Computers can only approximate computations involving real numbers.
  For instance, a computer's [decimal] answer to the simple problem 
-\begin_inset Formula \( \frac{1}{3} \)
+\begin_inset Formula $\frac{1}{3}$
 \end_inset 
 
  is 
@@ -3337,15 +3392,16 @@
 \emph default 
  to allow a tolerance factor, or the students will find it nearly impossible
  to exactly match the computers idea of the answer.
-\end_float 
+\end_inset 
+
 , though you may find the default too large for some problems.
  There are two kinds of tolerance.
  For some answer 
-\begin_inset Formula \( a \)
+\begin_inset Formula $a$
 \end_inset 
 
  and a tolerance 
-\begin_inset Formula \( t \)
+\begin_inset Formula $t$
 \end_inset 
 
 ,
@@ -3367,21 +3423,22 @@
 \end_inset 
 
  will take anything in the range 
-\begin_inset Formula \( a\pm t \)
+\begin_inset Formula $a\pm t$
 \end_inset 
 
 .
  So if 
-\begin_inset Formula \( a=10 \)
+\begin_inset Formula $a=10$
 \end_inset 
 
  and 
-\begin_inset Formula \( t=2 \)
+\begin_inset Formula $t=2$
 \end_inset 
 
 , then anything between 8 and 12 is acceptable
-\begin_float footnote 
-\end_deeper 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 For much the same reasons a tolerance is almost always a good idea, it's
@@ -3390,7 +3447,7 @@
 exactly
 \emph default 
  
-\begin_inset Formula \( a\pm t \)
+\begin_inset Formula $a\pm t$
 \end_inset 
 
  will be accepted by the computer.
@@ -3413,7 +3470,8 @@
 
  is OK.
  (Don't use too many more zeros, though you can use less if you like.)
-\end_float 
+\end_inset 
+
 .
  Any number in the tolerance field 
 \emph on 
@@ -3424,7 +3482,6 @@
 %
 \series default 
  symbol is an absolute tolerance.
-\begin_deeper 
 \layout Enumerate
 
 a 
@@ -3442,7 +3499,7 @@
 \end_inset 
 
  will take anything in the range 
-\begin_inset Formula \( a\pm at \)
+\begin_inset Formula $a\pm at$
 \end_inset 
 
 , where 
@@ -3460,11 +3517,11 @@
 \series default 
  symbol is a relative tolerance.
  For example, 
-\begin_inset Formula \( a=10 \)
+\begin_inset Formula $a=10$
 \end_inset 
 
  and 
-\begin_inset Formula \( t=10\% \)
+\begin_inset Formula $t=10\%$
 \end_inset 
 
  will accept anything between 9 and 11.
@@ -3768,7 +3825,9 @@
 
 There are many variable naming conventions, covering both how to name and
  how to capitalize variables
-\begin_float footnote 
+\begin_inset Foot
+collapsed true
+
 \layout Standard
 
 The author favors 
@@ -3809,7 +3868,8 @@
 COEF_FRICTION
 \family default 
 , or something else.
-\end_float 
+\end_inset 
+
 .
  It is a good idea to adopt a standard.
  If you are working with a group, you may wish to discuss it in your group
@@ -3941,14 +4001,23 @@
 See the string: <b>$stringVar</b><br />
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 353 99
-file numericalResponseVarInText.eps
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename numericalResponseVarInText.eps
+	display color
+	size_type 0
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 353pt
+	lyxheight 99pt
 \end_inset 
 
 
@@ -3960,7 +4029,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 If you save that and hit 
 \series bold 
 View
@@ -4048,7 +4118,12 @@
  For now, let's just look at some simple examples.
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout LyX-Code
 
 $a = -3.0;
@@ -4066,7 +4141,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 In the 
 \series bold 
 Script
@@ -4151,7 +4227,12 @@
  the function list.
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout LyX-Code
 
 $a = &random(1.0,10.0,1.0);
@@ -4173,7 +4254,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
 If you put the script in figure 
 \begin_inset LatexCommand \ref{Sample Random Calls figure}
 
@@ -4271,15 +4353,23 @@
 
 Now you have all the tools to create those wonderful dynamic, randomized
  problems that you've seen in LON-CAPA.
-\begin_float fig 
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 197
-file numericalResponseSlopeProblem.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename numericalResponseSlopeProblem.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 197pt
 \end_inset 
 
 
@@ -4291,7 +4381,8 @@
 \end_inset 
 
 
-\end_float 
+\end_inset 
+
  For example, try filling out your problem with the parameters shown in
  figure 
 \begin_inset LatexCommand \ref{Slope Problem Parameters Figure}
@@ -4438,25 +4529,35 @@
  Problems
 \layout Standard
 
-\begin_float fig 
+
+\begin_inset Float figure
+placement htbp
+wide false
+collapsed false
+
 \layout Standard
 \align center 
 
-\begin_inset Figure size 476 262
-file formulaResponse.eps
-width 3 80
-flags 9
-
+\begin_inset Graphics FormatVersion 1
+	filename formulaResponse.eps
+	display color
+	size_type 1
+	width 80page%
+	rotateOrigin center
+	lyxsize_type 1
+	lyxwidth 476pt
+	lyxheight 262pt
 \end_inset 
 
 
 \layout Caption
 
 Formula Response Problem
-\end_float 
+\end_inset 
+
 Formula response problems asks the student to type in a formula as an answer.
  If the answer is 
-\begin_inset Formula \( 2x^{2}+4 \)
+\begin_inset Formula $2x^{2}+4$
 \end_inset 
 
 , the student is allowed to type 
@@ -4493,7 +4594,7 @@
 As you may know, it is extremely difficult to determine whether a given
  expression is exactly equal to another expression in general.
  For example, is 
-\begin_inset Formula \( \sin 2x=2\sin x\cos x \)
+\begin_inset Formula $\sin 2x=2\sin x\cos x$
 \end_inset 
 
 ? Symbolically proving it one way or another is impossible in general.
@@ -4554,7 +4655,7 @@
 \layout Standard
 
 For 
-\begin_inset Formula \( 2x^{2}+4 \)
+\begin_inset Formula $2x^{2}+4$
 \end_inset 
 
 , with one variable 
@@ -4605,7 +4706,7 @@
 \layout Standard
 
 For 
-\begin_inset Formula \( 2x^{2}+3y^{3} \)
+\begin_inset Formula $2x^{2}+3y^{3}$
 \end_inset 
 
 , which has two variables, one could specify
@@ -4720,99 +4821,4 @@
 Sample Points
 \series default 
  to x@0,1,2,3 .
-\layout Comment
-
-TODO:
-\layout Comment
-
-* Get sampling problem figured out
-\layout Comment
-
-\SpecialChar ~
-
-\layout Comment
-
-\SpecialChar ~
-
-\newline 
-\SpecialChar ~
-
-\layout Comment
-
-Appendix A: Student Interface
-\layout Comment
-
-\begin_float fig 
-\layout Standard
-\align center 
-
-\begin_inset Figure size 152 353
-file studentInterface.eps
-flags 9
-
-\end_inset 
-
-
-\layout Caption
-
-Student Remote Control
-\begin_inset LatexCommand \label{Student Remote Control}
-
-\end_inset 
-
-
-\end_float 
-The Student Remote Control will automatically load whenever you log in to
- a LON-CAPA course as a student.
- The Student Remote Control contains most of the functions of the Author
- Remote Control and the following additional functions.
-\layout Comment
-
-
-\series bold 
-NAV (NAVIGATE CONTENTS)
-\series default 
- allows you to directly access resources from the course outline.
-\layout Comment
-
-
-\series bold 
-ARROWS (LEFT and RIGHT)
-\series default 
- allows you to move to the backward or forward through the course.
-\layout Comment
-
-
-\series bold 
-GRDS (MY GRADES)
-\series default 
- allows you to check your grades in the courses you are taking.
-\layout Comment
-
-
-\series bold 
-SBKM (SET BOOKMARK)
-\series default 
- allows you to bookmark pages for easy access.
-\layout Comment
-
-
-\series bold 
-VBKM (VIEW BOOKMARK)
-\series default 
- displays your bookmarks for easy access to bookmarked resources.
-\layout Comment
-
-
-\series bold 
-ANOT (ANOTATE)
-\series default 
- allows you to create personal notes.
-\layout Comment
-
-
-\series bold 
-LOGOUT (LOGOUT)
-\series default 
- will log you out of the LON-CAPA system.
 \the_end
Index: loncom/Makefile
diff -u loncom/Makefile:1.45 loncom/Makefile:1.46
--- loncom/Makefile:1.45	Mon Nov 19 18:31:43 2001
+++ loncom/Makefile	Fri Jul  5 12:12:31 2002
@@ -42,7 +42,8 @@
 	interface/lonnavmaps.pm interface/lonpreferences.pm interface/lonprintout.pm \
 	interface/lonsearchcat.pm interface/lontest.pm interface/lonchart.pm \
 	interface/loncommon.pm interface/loncreatecourse.pm interface/loncreateuser.pm \
-	interface/lonstatistics.pm metadata_database/searchcat.pl
+	interface/lonstatistics.pm metadata_database/searchcat.pl \
+	interface/lonhelp.pm
 
 OMTARGETS=auth/localauth.pm
 
Index: loncom/loncapa_apache.conf
diff -u loncom/loncapa_apache.conf:1.6 loncom/loncapa_apache.conf:1.7
--- loncom/loncapa_apache.conf:1.6	Mon Jun 24 10:36:26 2002
+++ loncom/loncapa_apache.conf	Fri Jul  5 12:12:31 2002
@@ -1,7 +1,7 @@
 ##
 ## loncapa_apache.conf -- Apache HTTP LON-CAPA configuration file
 ##
-## $Id: loncapa_apache.conf,v 1.6 2002/06/24 14:36:26 www Exp $
+## $Id: loncapa_apache.conf,v 1.7 2002/07/05 16:12:31 bowersj2 Exp $
 ##
 ## 1/11/2002 - Scott Harrison
 ## 2/19/2002 - Scott Harrison
@@ -12,7 +12,7 @@
 #
 # LON-CAPA Section (extensions to httpd.conf daemon configuration)
 #
-# ================================================================ DocumentRoot
+# ======================================================================== User
 
 DocumentRoot "/home/httpd/html"
 
@@ -37,7 +37,6 @@
 # ===================================================================== Aliases
 
 Alias /prtspool/ /home/httpd/prtspool/
-ScriptAlias /cgi-bin/ "/home/httpd/cgi-bin/"
 
 # ================================================================= Directories
 
@@ -122,7 +121,7 @@
 PerlHandler Apache::lonsequence
 </LocationMatch>
 
-<LocationMatch "^/(res|\~).*\.meta$>
+<LocationMatch "^/res/.*\.meta$>
 SetHandler perl-script
 PerlHandler Apache::lonmeta
 </LocationMatch>
@@ -451,6 +450,11 @@
 PerlHandler Apache::lonerrorhandler
 </Location>
 
+<LocationMatch "^/adm/help/.*\.hlp$">
+SetHandler perl-script
+PerlHandler Apache::lonhelp
+</LocationMatch>
+
 # ------------------------------------------------- Backdoor Adm Tests/Programs
 
 <Location /cgi-bin/loncron.pl>
@@ -578,7 +582,7 @@
 # -----------------------------------------------------------------------------
 
 
-# ====================================== Include machine-specific configuration
+# ================================================== Initiate mod_perl starting
 
 Include conf/loncapa.conf
 
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.43 loncom/interface/loncommon.pm:1.44
--- loncom/interface/loncommon.pm:1.43	Wed Jul  3 17:12:38 2002
+++ loncom/interface/loncommon.pm	Fri Jul  5 12:12:31 2002
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # a pile of common routines
 #
-# $Id: loncommon.pm,v 1.43 2002/07/03 21:12:38 ng Exp $
+# $Id: loncommon.pm,v 1.44 2002/07/05 16:12:31 bowersj2 Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -427,6 +427,49 @@
 }   #  end of sub linked_select_forms {
 
 ###############################################################
+
+
+=item help_open_topic($topic, $stayOnPage, $width, $height)
+
+Returns a string corresponding to an HTML link to the given help $topic, where $topic corresponds to the name of a .tex file in /home/httpd/html/adm/help/tex, with underscores replaced by spaces.
+
+$stayOnPage is a value that will be interpreted as a boolean. If true, the link will not open a new window. If false, the link will open a new window using Javascript. (Default is false.)
+
+$width and $height are optional numerical parameters that will override the width and height of the popped up window, which may be useful for certain help topics with big pictures included.
+
+=cut
+
+sub help_open_topic {
+    my ($topic, $stayOnPage, $width, $height) = @_;
+    $stayOnPage = 0 if (not defined $stayOnPage);
+    $width = 350 if (not defined $width);
+    $height = 400 if (not defined $height);
+    my $filename = $topic;
+    $filename =~ s/ /_/g;
+
+    my $template;
+
+    if (!$stayOnPage)
+    {
+        $template = <<"ENDTEMPLATE";
+<a href="javascript:void(open('/adm/help/${filename}.hlp', 'Help for $topic', 'menubar=0,s
+crollbars=1,width=$width,height=$height'))"><image
+  src="/adm/help/gif/smallHelp.gif"
+  border="0" alt="(Help: $topic)"></a>
+ENDTEMPLATE
+    }
+    else
+    {
+        $template = <<"ENDTEMPLATE";
+<a href="/adm/help/${filename}.hlp"><image
+  src="/adm/help/gif/smallHelp.gif"
+  border="0" alt="(Help: $topic)"></a>
+ENDTEMPLATE
+    }
+
+    return $template;
+
+}
 
 =item csv_translate($text) 
 

Index: doc/help/author.manual.texxml
+++ doc/help/author.manual.texxml
<texxml>
Author_Manual_Title_Page
	<file name="Author_Manual_Title_Page.tex"/>
	
	<section name="Introduction to LON-CAPA">
Author_LON-CAPA_Introduction
		<file name="Author_LON-CAPA_Introduction.tex"/>
		<subsection name="About This Manual">
About_Authors_Manual
			<file name="About_Authors_Manual.tex"/>
			</subsection>
		<subsection name="Login as Course Author">
Login_To_LON-CAPA
			<file name="Login_To_LON-CAPA.tex"/>
			</subsection>
		<subsection name="Author Remote Control">
Author_Remote_Control
			<file name="Author_Remote_Control.tex"/>
			</subsection>
		</section>

	<section name="Creating Content Using LON-CAPA">
Resource_Types
		 <file name="Resource_Types.tex"/>
		 <subsection name="Description of the Construction Space">
Construction_Space_Overview
			<file name="Construction_Space_Overview.tex"/>
			</subsection>
		<subsection name="How to Create New Content Pages">
Creating_New_Content_Pages
			<file name="Creating_New_Content_Pages.tex"/>
			</subsection>
		<subsection name="How to Edit Existing Content Pages">
How_To_Edit_Existing_Content_Pages
		        <file name="How_To_Edit_Existing_Content_Pages.tex"/>
			</subsection>
		<subsection name="Creating Online Problems Using LON-CAPA">
Creating_Online_Problems
			<file name="Creating_Online_Problems.tex"/>
			</subsection>
		<subsection name="Problem Types">
Problem_Types
			<file name="Problem_Types.tex"/>
Problem_Editor_Testing_Area
			<file name="Problem_Editor_Testing_Area.tex"/>
			</subsection>
		<subsection name="Foils">
Foils
			<file name="Foils.tex"/>
			</subsection>
		<subsubsection name="Radio Response Problems">
Radio_Response_Problems
			<file name="Radio_Response_Problems.tex"/>
			</subsubsection>
		<subsubsection name="Option Response Problems">
Option_Response_Problems
			<file name="Option_Response_Problems.tex"/>
			</subsubsection>
		<subsubsection name="String Response Problems">
String_Response_Problems
			<file name="String_Response_Problems.tex"/>
			</subsubsection>
		<subsubsection name="Numerical Response Problems">
Numerical_Response_Problems
			<file name="Numerical_Response_Problems.tex"/>
			</subsubsection>
		<subsubsection name="Formula Response Problems">
Formula_Response_Problems
			<file name="Formula_Response_Problems.tex"/>
			</subsubsection>
		<subsection name="Creating Radio Response Problems">
Creating_Radio_Response_Problems
			<file name="Creating_Radio_Response_Problems.tex"/>
			<subsubsection name="Randomization">
Radio_Response_Randomization
				<file name="Radio_Response_Randomization.tex"/>
				</subsubsection>
			</subsection>		
		<subsection name="Option Response Problems">
			<tex content="\index{Option Response}\label{Create Option Response Problem}"/>
			<subsubsection name="Option Response Problems with Concept Groups">
Option_Response_Problem_Figure
				<file name="Option_Response_Problem_Figure.tex"/>
Option_Response_Problem_Parts
				<file name="Option_Response_Problem_Parts.tex"/>
				</subsubsection>
			<subsubsection name="Example: Concept Group">
Option_Response_Concept_Group_Example
				<file name="Option_Response_Concept_Group_Example.tex"/>
				</subsubsection>
			<subsubsection name="Example: Matching Problem">
Option_Response_Matching_Example
				<file name="Option_Response_Matching_Example.tex"/>
				</subsubsection>
			<subsubsection name="Creating Option Problems">
Option_Response_Problem_Creation
				<file name="Option_Response_Problem_Creation.tex"/>
				</subsubsection>
			<subsubsection name="Simple Option Response: No Concept Groups">
Option_Response_Simple
				<file name="Option_Response_Simple.tex"/>
				</subsubsection>
			</subsection>
		<subsection name="Creating a String Response Problem">
String_Response_Problem_Creation
			<file name="String_Response_Problem_Creation.tex"/>
			</subsection>
		<subsection name="Creating Numerical Response and Formula Response Problems">
About_Numerical_and_Formula_Response
			<file name="About_Numerical_and_Formula_Response.tex"/>
Author_Numerical_and_Formula
			<file name="Author_Numerical_and_Formula.tex"/>
			</subsection>
		</section>

	<section name="Publishing Your Resources">
Publishing_Intro
		<file name="Publishing_Intro.tex"/>
		<subsection name="What is Metadata?">
Metadata_Description
			<file name="Metadata_Description.tex"/>
			</subsection>
		<subsection name="Publishing A Resource">
Publishing_A_Resource
			<file name="Publishing_A_Resource.tex"/>
Publishing_Author_Tutorial_Segue
			<file name="Publishing_Author_Tutorial_Segue.tex"/>
			</subsection>
		</section>

	<section name="Creating A Course: Maps and Sequences">
Creating_A_Course_Intro
		<file name="Creating_A_Course_Intro.tex"/>
		<subsection name="Creating Sequences">
Sequence_Definition
			<file name="Sequence_Definition.tex"/>
Sequence_Editor_Selection
			<file name="Sequence_Editor_Selection.tex"/>
			</subsection>
		<subsection name="Creating a Simple .sequence With The Simple Editor">
Sequence_Simple_Editor_Creation
			<file name="Sequence_Simple_Editor_Creation.tex"/>
			</subsection>
		<subsection name="Creating a Simple .sequence With The Advanced Editor">
Sequence_Advanced_Editor_Creation
			<file name="Sequence_Advanced_Editor_Creation.tex"/>
			</subsection>
		<subsection name="Page Maps">
Sequence_Page_Maps
			<file name="Sequence_Page_Maps.tex"/>
			</subsection>
		<subsection name="Creating a Course: Top-level Sequence">
Sequence_Top-Level
			<file name="Sequence_Top-Level.tex"/>
			</subsection>
		</section>

	<section name="Numerical Response And Formula Response Questions">
Numerical_Response_Introduction
		<file name="Numerical_Response_Introduction.tex"/>
		<subsection name="The Parts of a Numerical Response Problem">
Numerical_Response_Parts_A
			<file name="Numerical_Response_Parts_A.tex"/>
			<tex content="\item "/>
Tolerance
			<file name="Tolerance.tex"/>
			<tex content="\item "/>
Significant_Figures
			<file name="Significant_Figures.tex"/>
Numerical_Response_Parts_B
			<file name="Numerical_Response_Parts_B.tex"/>
			</subsection>
		<subsection name="Simple Numerical Response Answer">
Numerical_Response_Intro
			<file name="Numerical_Response_Intro.tex"/>
			</subsection>
		<subsection name="Simple Script Usage">
Script_Tutorial_Intro
			<file name="Script_Tutorial_Intro.tex"/>
Numerical_Response_Simple_Example
			<file name="Numerical_Response_Simple_Example.tex"/>
Variable_Naming_Conventions
			<file name="Variable_Naming_Conventions.tex"/>
Numerical_Response_Tutorial_A
			<file name="Numerical_Response_Tutorial_A.tex"/>
			<subsubsection name="Variables in Scripts">
Variables_in_Scripts
				<file name="Variables_in_Scripts.tex"/>
Variable_Tutorial_A
				<file name="Variable_Tutorial_A.tex"/>
				</subsubsection>
			<subsubsection name="Variables in the Text Block">
Variables_in_the_Text_Block
				<file name="Variables_in_the_Text_Block.tex"/>
				</subsubsection>
			<subsubsection name="Variables in the Answer Block">
Variables_in_the_Answer_Block
				<file name="Variables_in_the_Answer_Block.tex"/>
				</subsubsection>
			</subsection>
		<subsection name="Calling Functions">
Calling_Functions
			<file name="Calling_Functions.tex"/>
			<subsubsection name="Numerical Response Randomization">
				<tex content="If you're doing this as a tutorial, try a few random seeds to see what happens."/>
				</subsubsection>
			</subsection>
		<subsection name="Dynamic, Randomized Problems: Putting It All Together">
			<tex content="Now you have all the tools to create those wonderful dynamic, randomized problems that you've seen in LON-CAPA."/>
Numerical_Response_Advanced_Example
			<file name="Numerical_Response_Advanced_Example.tex"/>
			</subsection>
		<subsection name="Units, Format">
Numerical_Response_Units
			<file name="Numerical_Response_Units.tex"/>
Numerical_Response_Format
			<file name="Numerical_Response_Format.tex"/>
			</subsection>
		<subsection name="For More Information">
Scripting_Help
			<file name="Scripting_Help.tex"/>
			</subsection>
		<subsection name="Formula Response">
Formula_Response_Problems
			<file name="Formula_Response_Problems.tex"/>
			<subsubsection name="Sample Specifications">
Formula_Response_Sampling
				<file name="Formula_Response_Sampling.tex"/>
				</subsubsection>
			<subsubsection name="Formula Notes">
				<tex content="\begin {itemize}"/>
				<tex content="\item"/>
Formula_Response_Limitations
				<file name="Formula_Response_Limitations.tex"/>
				<tex content="\item"/>
Formula_Tolerance
				<file name="Formula_Tolerance.tex"/>
				<tex content="\end{itemize}"/>
				</subsubsection>
			<subsubsection name="Exaple Formula Response">
Formula_Response_Example
				<file name="Formula_Response_Example.tex"/>
				</subsubsection>
			</subsection>
		</section>

	</texxml>

Index: doc/help/latexSplitter.py
+++ doc/help/latexSplitter.py
"""Latex Splitter quickee python app.

This application assists in spliting large Latex files into lots of
smaller ones.

To use this application, paste a latex file into the window. Highlight
the section you wish to save as an independent fragment. Then hit the
button, give the fragment a file name and a topic, and save
it. Continue until you've retreived everything out of the file you
want.

Starting it with a command-line parameter will try to load that file
into the text box.

This program may require Python as high as 2.2, though 2.1 should
do."""

from Tkinter import *
from ScrolledText import *
import anydbm
import sys
import string

dirprefix = "/home/httpd/html/adm/help/"

class LatexSplitter:
    def __init__(self, master):
        self.frame = Frame(master)
        self.frame.pack()

        self.label = Label(self.frame, text = "For documentation on" 
                           "this program, consult the source code.")
        self.label.pack()

        self.text = ScrolledText(self.frame, width=120, height = 40);
        self.text.pack(fill = BOTH, expand = 1)

        self.l2 = Label(self.frame, text = "File Root Name (no .tex):")
        self.l2.pack()
        self.topic = Text(self.frame, width=60, height = 1)
        self.topic.pack()

        self.button = Button(self.frame, text = "Split & Save", \
                             command = self.splitAndSave)
        self.button.pack()

        if len(sys.argv) > 1:
            f = file(sys.argv[1])
            self.text.insert("1.0", f.read())
            f.close()

    def splitAndSave(self):
        selection = self.text.get("sel.first", "sel.last")
        topic = string.strip(self.topic.get("1.0", "end"))
        filename = dirprefix + string.replace(topic, " ", "_") + ".tex"

        try:
            f = file(filename, 'w')
        except:
            return
        f.write(selection)
        f.close()

        self.topic.delete("1.0", END)
        self.text.delete("sel.first", "sel.last")

        f = file("latexSplitterTempResults", 'w')
        f.write(self.text.get("1.0", END))
        f.close()

root = Tk()
app = LatexSplitter(root)
root.mainloop()


Index: doc/help/rebuildLabelHash.pl
+++ doc/help/rebuildLabelHash.pl
#!/usr/bin/perl

use strict;
use GDBM_File;

my $dirprefix = "/home/httpd/html/adm/help/";

# if the topic hash exists, kill it
unlink 'fragmentLabels.gdbm' if ( -e $dirprefix . 'fragmentTopics.gdbm' );

tie (my %fragmentLabels, 'GDBM_File', $dirprefix . 'fragmentLabels.gdbm', 1, 0);
my $error = 0;

chdir $dirprefix;

while (<*.tex>) 
{
    my $file;
    $file = $_;
    open F, $file;
    my $contents = join("\n", <F>);
    my $label;
    
    # Search for labels, of the form '\label{labelname}'
    foreach $label ( $contents =~ /\\label\{([^}]*)\}/g )
    {
	if (exists $fragmentLabels{$label} )
	{
	    print "***ERROR: '$label' in both $fragmentLabels{$label} " .
	          "and $file. \n";
	    $error = 1;
	}
	$fragmentLabels{$label} = $file;
    }
}

if ($error == 0)
{
    print "There were no duplicate labels. Database rebuilt.\n";
}
else
{
    print "There were errors. You must correct the duplicate labels.\n";
}

untie %fragmentLabels;

Index: doc/help/simpleEdit.py
+++ doc/help/simpleEdit.py
"""simpleEdit can be used to edit the tex fragments in context
determined by a texxml file.

Use:

python simpleEdit.py [name of texxml file]

simpleEdit will read the texxml file, and present the referenced tex
fragments in order determined by the file. When you save (CTRL-S),
simpleEdit will save all the tex fragments back to their little
files.

Very, very simple.
"""

import sys
if len(sys.argv) < 2:
    print "Usage: python simpleEdit.py [name of texxml file]"
    print "See top of source code for usage."
    print "To save files, press CTRL-s in the editor."
    sys.exit()

import xml.parsers.expat

dirprefix = "/home/httpd/html/adm/help/tex/"

fileList = []

def startElement(name, attrs):
    if name == "file":
        fileList.append(str(attrs["name"]))

p = xml.parsers.expat.ParserCreate()
p.StartElementHandler = startElement
f = file(sys.argv[1], 'r')
p.Parse(f.read())


from Tkinter import *
from ScrolledText import *
import string
import os

class simpleEditor:
    def __init__(self, master):
        self.frame = Frame(master)
        self.frame.pack()

        self.label = Label(self.frame, text = "For documentation on" 
                           "this program, consult the source code.")
        self.label.pack()

        self.text = ScrolledText(self.frame, width=120, height = 40);
        self.text.pack(fill = BOTH, expand = 1)

        self.searchText = Text(self.frame, width = 40, height = 1);
        self.searchText.pack()
        self.searchButton = Button(self.frame, text = "Search",
                                   command = self.search)
        self.searchButton.pack()

        self.button = Button(self.frame, text = "Save", \
                             command = self.save)
        self.button.pack()

    def search(self):
        searchText = self.searchText.get("1.0", END)
        searchText = searchText.strip()
        print self.text.index(INSERT + "+%ic" % len(searchText))
        pos = self.text.search(searchText,
                               self.searchText.index(INSERT) +
                               "+%ic" % (len(searchText) + 1))
        self.text.see(pos)
        self.text.tag_add(SEL, pos, pos + "+%ic" % len(searchText))
        self.text.mark_set(INSERT, pos)

    def load(self):
        """Loads in all the tex files."""

        colors = ["#FFFFFF", "#CCCCCC"]

        c = 0

        for f in fileList:
            f = file(dirprefix + f, 'r')
            tex = f.read()
            f.close()
            self.text.tag_config("texfile%i" % c,
                                 background = colors[c%len(colors)])
            self.text.insert(END, tex, "texfile%i" % c)
            self.text.insert(END, "\n\n") # prettier
            c += 1

    def save(self):
        c = 0
        
        for f in fileList:
            tex = self.text.get("texfile%i.first" % c,
                                "texfile%i.last" % c)
            os.rename ( dirprefix + f, dirprefix + f + "~" )
            f = file(dirprefix + f, 'w')
            f.write(tex)
            f.close()
            c += 1

            


root = Tk()
app = simpleEditor(root)
app.load()
root.mainloop()


Index: doc/help/texxml2latex.pl
+++ doc/help/texxml2latex.pl
#!/usr/bin/perl

use strict;
use HTML::TokeParser;
use GDBM_File;

# accept texxml document on standard in
my $p = HTML::TokeParser->new( $ARGV[0] );
my $dirprefix = "/home/httpd/html/adm/help/tex/";

# Print the header
open (LATEX_FILE, $dirprefix . "Latex_Header.tex");
print <LATEX_FILE>;


while (my $token = $p->get_token())
{
    my $type = $token->[0];
    if ($type eq 'S')
    {
	my $tag = $token->[1];
	my $attr = $token->[2];
	if ($tag eq 'section')
	{
	    my $title = $attr->{'name'};
	    print "\\section{$title}\n\n";
	}

	if ($tag eq 'subsection')
	{
	    my $title = $attr->{'name'};
	    print "\\subsection{$title}\n\n";
	}

	if ($tag eq 'subsubsection')
	{
	    my $title = $attr->{'name'};
	    print "\\subsubsection{$title}\n\n";
	}

	if ($tag eq 'file')
	{
	    my $file = $attr->{'name'};
	    open (LATEX_FILE, $dirprefix . $file);
	    print <LATEX_FILE>;
	}

	if ($tag eq 'tex')
	{
	    print "\n";
	    print $attr->{'content'};
	    print "\n";
	}
    }
}

# Print out the footer.
open (LATEX_FILE, $dirprefix . "Latex_Footer.tex");
print <LATEX_FILE>;

Index: loncom/build/help_graphics_converter.pl
+++ loncom/build/help_graphics_converter.pl
# The LearningOnline Network
# help_graphics_converter - converts help .png into .gif and .eps
#
# This file is part of the LearningOnline Network with CAPA (LON-CAPA).
#
# LON-CAPA 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.
#
# LON-CAPA 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 LON-CAPA; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
#
# /home/httpd/html/adm/gpl.txt
#
# http://www.lon-capa.org/
#
# YEAR=2002
# 7/4, Jeremy Bowers
#
###

use strict;

my $dirprefix = "/home/httpd/html/adm/help/";

# Check that the png directory exists
if (not (-d $dirprefix . "png/"))
{ die "Can't convert help graphics because the png directory is not ".
      "installed."; }

mkdir $dirprefix . "gif/";
mkdir $dirprefix . "eps/";

foreach my $file (glob($dirprefix . "png/*.png"))
{
    my $filename = substr($file, rindex($file, "/") + 1);
    my $gifdest = $dirprefix . "gif/" . substr($filename, 0, -4) . ".gif";
    my $epsdest = $dirprefix . "eps/" . substr($filename, 0, -4) . ".eps";
    
    
    print "Converting $filename... gif";
    system ("convert $file $gifdest\n") if (not (-s $gifdest));
    print " eps";
    system ("convert $file $epsdest\n") if (not (-s $epsdest));
    print " done.\n";
}

Index: loncom/html/adm/help/tex/About_Authors_Manual.tex
+++ loncom/html/adm/help/tex/About_Authors_Manual.tex

Throughout this manual, keywords and phrases literally present on the computer
screen will be referred to in \textbf{bold type}. Function names and scripts
will be shown in a \texttt{typewriter font}.

Much of this document can be used as a tutorial that will introduce you to
the authoring system. In particular, chapters \ref{Author Interface} through
\ref{Creating a Course} comprise a basic tutorial that can get you started
using LON-CAPA, even with no previous LON-CAPA experience.

For additional help, visit our FAQ at \texttt{http://help.loncapa.org/}.


Index: loncom/html/adm/help/tex/About_Numerical_and_Formula_Response.tex
+++ loncom/html/adm/help/tex/About_Numerical_and_Formula_Response.tex

Numerical Response problems are answered by entering a number and an optional
unit. For instance, a numerical response problem might have an answer of
$2m/s^{2}$. Formula Response problems are answered by entering a mathematical
formula. For instance, a numerical response problem might have an answer
of $x^{2}+11$. The answer may be in any equivalent format. For instance,
for $x^{2}+11$, the system will also accept $x*x+11$ or $x^{2}+21-10$.

Index: loncom/html/adm/help/tex/Author_LON-CAPA_Introduction.tex
+++ loncom/html/adm/help/tex/Author_LON-CAPA_Introduction.tex

LON-CAPA is a web-based interface that helps to organize and present your
course website, deliver and manage problems, and manage student enrollment.
All author functions are done through a web browser (Netscape 4.x or higher,
a recent Mozilla, or IE 5+ required).

At this time, you should have:

\begin{itemize}
\item developed your objectives for your course. 
\item developed your problems for input into LON-CAPA and determined the appropriate
question formats.
\end{itemize}

Index: loncom/html/adm/help/tex/Author_Manual_Title_Page.tex
+++ loncom/html/adm/help/tex/Author_Manual_Title_Page.tex

\title{Learning \emph{Online} Network with CAPA\\
\emph{~}\\
\emph{\Large Author's Tutorial And Manual}}

\maketitle
\vfill{}
\begin{center}~\end{center}

\begin{center}John Williamson, Felicia Berryman, Jeremy Bowers\end{center}

~ 

\begin{center}Laboratory for Instructional Technology in Education\\
and the\\
Office of Medical Education Research and Development\\
Michigan State University\\
\end{center}
\newpage

\tableofcontents{}
\newpage


Index: loncom/html/adm/help/tex/Author_Numerical_and_Formula.tex
+++ loncom/html/adm/help/tex/Author_Numerical_and_Formula.tex

Creating Numerical Response and Formula Response problems starts the same
as the other problem types, but because of the power of Numerical Response
and Formula Response problems, they are covered in their own section after
the end of the tutorial. For more information about these problem types,
please see section \ref{Numerical Response} for Numerical Response problems
and section \ref{Formula Response} for Formula Response problems.

Index: loncom/html/adm/help/tex/Author_Remote_Control.tex
+++ loncom/html/adm/help/tex/Author_Remote_Control.tex

The Author Remote Control
will automatically load whenever you log in to LON-CAPA as the course instructor.
The Author Remote Control is a separate window in your browser, and is automatically
sized and placed in the upper left of the screen. The Remote Control is a
tool that allows you to switch between functions and roles within LON-CAPA.
%
\begin{figure}
\begin{center}\includegraphics[  height=0.50\paperwidth]{authorRemote}\end{center}


\caption{Author Remote Control\label{Author Remote Control Figure}}
\end{figure}


When you move your mouse over the buttons in the remote, the sixteen gray
boxes will show a reminder of what that button does.

\begin{itemize}
\item \textbf{ROLES (CHOOSE ROLE)} allows you to select which user role to assume
for this session.
\item \textbf{COM (COMMUNICATION)} allows you to access the communication functions
in the system.
\item \textbf{CUSR (USER ROLES)} brings up a page that allows you to create new
users and change user privileges.
\item \textbf{CSTR (CONSTRUCT)} displays the construction space for your account.
\item \textbf{RES (RESOURCE SPACE)} allows you to browse the LON-CAPA network directory.
\item \textbf{SRC (SEARCH LIBRARY)} brings up a screen that lets you search the
LON-CAPA resources using multiple criteria.
\item \textbf{PREF (PREFERENCES)} brings up a screen that allows you to change
some preferences.
\item \textbf{EXIT (LOGOUT)} will log you out of the LON-CAPA system.
\end{itemize}

Index: loncom/html/adm/help/tex/Calling_Functions.tex
+++ loncom/html/adm/help/tex/Calling_Functions.tex

With variables, you can store strings or numbers. \textbf{Functions} allow
you to manipulate these strings or numbers. Functions work like mathematical
functions: They take some number of arguments in, and return one argument,
usually a number or a string for our purposes. There are a lot of functions
available in LON-CAPA. You can see a complete list at http://mileva.lite.msu.edu/loncapadocs/homework/homework5.html.
For now, let's just look at some simple examples.

%
\begin{figure}
\begin{lyxcode}
\$a~=~-3.0;

\$b~=~\&sin(\$a);

\$c~=~\&pow(3.0,~\&abs(\$a));
\end{lyxcode}

\caption{Some Function Calls\label{Some Function Calls Figure}}
\end{figure}
In the \textbf{Script} block, function names start with \textbf{\&}. Some
example function calls are shown in figure \ref{Some Function Calls Figure}.
You can see that functions can take either variables, numbers, or the results
of other function calls as parameters. The \texttt{\&sin} function returns
the sine of an angle expressed in radians. \texttt{\&pow} raises the first
parameter to the power of the second parameter. \texttt{\&abs} returns the
absolute value of the argument.

Index: loncom/html/adm/help/tex/Construction_Space_Overview.tex
+++ loncom/html/adm/help/tex/Construction_Space_Overview.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{constructionSpace}\end{center}


\caption{Construction Space\label{Construction Space Figure}}

Contents of the Construction Space:

\begin{tabular}{|c|p{5in}|}
\hline 
\textbf{Button Name}&
\textbf{Description}\\
\hline
\hline 
Publish this Resource&
Opens the Resource Publishing window.\\
\hline 
List Directory&
Lists the contents of the current working directory\\
\hline 
Copy&
Type a new name in the entry box to make a copy the current resource\\
\hline 
Browse&
Helps you select a file to upload\\
\hline 
Upload File&
Uploads the selected file to your Construction Space\\
\hline 
Retrieve Old Version&
Load an older version of a resource if you have multiple versions\\
\hline 
Delete&
Deletes the current resource\\
\hline 
Rename&
Type a new name in the associated entry box to rename a resource\\
\hline 
New Subdirectory&
Type a name in the entry box to create a new directory\\
\hline
\end{tabular}
\end{figure}
The Construction Space
is the section of LON-CAPA where you create and manage your course resources.
The figure explains what each button does.


Index: loncom/html/adm/help/tex/Creating_A_Course_Intro.tex
+++ loncom/html/adm/help/tex/Creating_A_Course_Intro.tex

\label{Creating a Course}

In order to create a useful course, we need to arrange our raw materials
so that students can use them.

Index: loncom/html/adm/help/tex/Creating_New_Content_Pages.tex
+++ loncom/html/adm/help/tex/Creating_New_Content_Pages.tex
\label{Creating New Content Pages}

\textbf{Content Pages} are HTML documents that display the course information
you are presenting. 

Many users use tools such as Dreamweaver to create web pages. To upload HTML
files generated with such tools, you can use the \textbf{Browse} button in
the Construction Space, locate your HTML file, and use the \textbf{Upload
File} button to create a content page in LON-CAPA. Remember to upload any
graphics your generated web pages may have included.

To create new Content Pages, do the following:

\begin{enumerate}
\item Click the \textbf{CSTR} button on the LON-CAPA remote. Your web page will
change to your Construction Space.
\item In the Location bar of your browser, type in the full URL of the new Content
Page. Make sure the last part of the URL ends with {}``.html'', for example,
\\
\emph{http://www.s10.lite.msu.edu/priv/username/new\_resource.html} .\\
Press the Return or Enter key.
\item Type the content into the editor, \emph{OR} copy and paste HTML source code
obtained through the use of some other HTML authoring program into the editor.
\item Optionally, click the \textbf{View} button to preview your Content Page.
\item Finally, click the \textbf{Save this} button \emph{OR} click the \textbf{Save
and then attempt to clean HTML} button.
\end{enumerate}
Repeat this process as many times as necessary to create your Content Pages. 

If you're following this as a tutorial, create at least one content page,
which we'll use later as raw material. Visit the FAQ at \texttt{http://help.lon-capa.org/} if you get {}``unmatched
tag'' warnings.


Index: loncom/html/adm/help/tex/Creating_Online_Problems.tex
+++ loncom/html/adm/help/tex/Creating_Online_Problems.tex

If you're following this as a tutorial, go ahead and make one of each of
these problem types now. We'll be using them later as raw material to assemble
maps and sequences.

While several problem types are listed here, in LON-CAPA, all problems are
actually the same. All problems are written in XML, which can be obtained
and edited with the \textbf{EditXML} button you'll see. The problem types
listed in this manual are actually just templates. As your knowledge advances,
you may wish to play with the XML representation directly to see what you
can do.

Index: loncom/html/adm/help/tex/Creating_Radio_Response_Problems.tex
+++ loncom/html/adm/help/tex/Creating_Radio_Response_Problems.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{creatingNewProblemResource}\end{center}


\caption{Creating A New Problem Resource\label{Creating a new problem resource}}
\end{figure}
To create a Radio Response\index{Radio Response} problem, create a new resource
as described in section \ref{Creating New Content Pages}. This is a {}``problem''
resource so the URL must end in {}``.problem''. You should see a screen
as in figure \ref{Creating a new problem resource}.%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{radioResponse2}\end{center}


\caption{Radio Response Creation Form\label{Radio Response Creation Form}}
\end{figure}
 You will need to specify the question text and foil statements.

\begin{enumerate}
\item In the drop-down option box, 
select \textbf{Radio Response Problem}, and click the \textbf{New Problem}
button.
\item Click the \textbf{Edit} button above the sample problem to enter edit mode.
You should see an editing screen.
\item In the \textbf{Text Block} at the top of the problem, remove the sample text
and type the question for your problem. For example, {}``What is two plus
two?''
\item Locate the \textbf{Response: One of N statements} element. In the \textbf{Max
Number of Shown Foils} text box, place the number of foils you wish to display
to the student.
\item Locate \textbf{Foil 1}. Remove the text that is in the text box and put the
\emph{correct answer} for the problem in the \textbf{Text Block}. For example,
{}``Four.'' Make sure this is set to \textbf{true} in the \textbf{Correct
Option} field.
\item Below it, you will see \textbf{Foil 2}. Remove the text in the text box and
put an \emph{incorrect answer} for the problem. For instance, {}``Purple.''
Make sure this is set to \textbf{false} in the \textbf{Correct Option} field.
\item Repeat the previous step until you've filled in all of the other incorrect
answers you wish to offer the students.
\item Once you've filled in all the incorrect answers, change the \textbf{Correct
Option}s on the other foils to \textbf{Unused}.
\item %
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{radioResponseHint}\end{center}


\caption{Hint Element\label{Radio Response Hint Element Figure}}
\end{figure}
Scroll down to the Hint element.
Type some text that will help students when they answer incorrectly. You
may delete the hint by selecting \textbf{Yes} from the \textbf{Delete} drop-down
box.
\item Click the \textbf{Submit Changes} button located at the top of the frame.
If you do not do this, none of your changes will be saved.
\end{enumerate}
The \textbf{Correct Option} drop down box controls whether or not a given
answer will be accepted as a correct answer. If it is set to \textbf{true},
that answer will be considered a correct answer. Any number of foils can
be marked \textbf{true}, but only one will be shown to any given student.
If it is set to \textbf{false}, it will be considered an incorrect answer.
If it is set to \textbf{Unused}, the system will not use that foil.


Index: loncom/html/adm/help/tex/Foils.tex
+++ loncom/html/adm/help/tex/Foils.tex

In the LON-CAPA system, a \textbf{Foil\index{Foil}} is the statement after
the drop-down box or radio button in a Radio Response or Option Response
problem. Foils do not need to be text; they can be images or other resources.

Index: loncom/html/adm/help/tex/Formula_Response_Example.tex
+++ loncom/html/adm/help/tex/Formula_Response_Example.tex

A very simple formula response problem: 

In the \textbf{Script}, place the following:

\begin{lyxcode}
\$slope~=~\&random(-5.0,5.0,.5);

\$yint~~=~\&random(-5.0,5.0,.5);

\$answer~=~{}``\$slope{*}x~+~(\$yint)'';
\end{lyxcode}
\begin{itemize}
\item In the \textbf{Text Block}, place the following: {}``For a line with slope
\$slope and y-intercept \$yint, what is y equal to?''
\item In the \textbf{Answer}, place the following: \$answer
\item Set the Tolerance to .000001.
\item Set the \textbf{Sample Points} to x@0,1,2,3 .\end{itemize}

\end{document}

Index: loncom/html/adm/help/tex/Formula_Response_Limitations.tex
+++ loncom/html/adm/help/tex/Formula_Response_Limitations.tex
The formula evaluator can not handle things of the form {}``x + - y''.
If you have a random variable that may be positive or negative (as in the
example following this section), you can try wrapping the references to that
variable in parenthesis. As always, it is a good idea to try out several
randomized versions of your problems to make sure everything works correctly.
Index: loncom/html/adm/help/tex/Formula_Response_Problems.tex
+++ loncom/html/adm/help/tex/Formula_Response_Problems.tex

\index{Formula Response}\label{Formula Response}

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{formulaResponse}\end{center}


\caption{Formula Response Problem}
\end{figure}
Formula response problems asks the student to type in a formula as an answer.
If the answer is $2x^{2}+4$, the student is allowed to type {}``2{*}x{*}x+4'',
{}``x{*}x + x{*}x + 4'', {}``2{*}x\textasciicircum{}2 + 14 - 10'', or
any other equivalent expression. Formula Response problems have many of the
same characteristics of Numerical Response problems, including the ability
to run scripts, dynamically generate answers, etc. 

Index: loncom/html/adm/help/tex/Formula_Response_Sampling.tex
+++ loncom/html/adm/help/tex/Formula_Response_Sampling.tex

As you may know, it is extremely difficult to determine whether a given expression
is exactly equal to another expression in general. For example, is $\sin 2x=2\sin x\cos x$?
Symbolically proving it one way or another is impossible in general. Therefore,
LON-CAPA uses a sampling system. If your answer and the student's answer
agree at the sampling points within your given tolerance factor, the student's
answer will be accepted, otherwise it will be rejected.

To specify where to sample the formulas for determining whether the student's
answer is correct, you need to put a sampling specification in the \textbf{Sample
Points}\index{Sample Points} field. The sampling specifications takes the
following format:

\begin{enumerate}
\item A comma separated list of the variables you wish to interpret,
\item followed by {}``@'' (not in quotes),
\item followed by any number of the following two things, separated by semi-colons:

\begin{enumerate}
\item a comma separated list of as many numbers as there are variables, which specifies
one sampling point, OR
\item a comma separated list of as many numbers as there are variables, followed
by a colon, followed by another list of as many numbers as there are variables,
followed by a \#, followed by an integer.
\end{enumerate}
\end{enumerate}
The first form specifies one point to sample. The second form specifies a
range for each variable, and the system will take as many random samples
from that range as the number after the \#.

For $2x^{2}+4$, with one variable {}``x'', one could specify

\begin{itemize}
\item {}``x@2'', which will sample the answers only at 2. (This is generally
a bad idea, as the student could get lucky and match at that point)
\item {}``x@1:5\#4'' will takes 4 samples from somewhere between 1 and 5.
\item {}``x@1:5\#4;10'' will takes 4 samples from somewhere between 1 and 5,
and also sample at 10.
\end{itemize}
For $2x^{2}+3y^{3}$, which has two variables, one could specify

\begin{itemize}
\item {}``x,y@4,5:10,12\#4;0,0'', which take four samples from the box determined
by the points (4, 5) and (10, 12), and also sample the point (0, 0).
\end{itemize}

Index: loncom/html/adm/help/tex/Formula_Tolerance.tex
+++ loncom/html/adm/help/tex/Formula_Tolerance.tex
\textbf{Never use relative tolerance in Formula Response problems.\index{tolerance, in formula response}\index{relative tolerance, in formula response}}
Relative tolerance is poorly defined in Formula Response problems. Always
use absolute tolerance.
Index: loncom/html/adm/help/tex/How_To_Edit_Existing_Content_Pages.tex
+++ loncom/html/adm/help/tex/How_To_Edit_Existing_Content_Pages.tex

You may edit any Content Pages that have been created.

To edit Content Pages: 

\begin{enumerate}
\item Click the \textbf{CSTR} button on the LON-CAPA Remote. Your web page will
change to your Construction Space.
\item Click on the link for the name of the Content Page to edit. The Content Page
editor will load and display the current edition of the Content Page.
\item Press the \textbf{Edit} button. Edit the HTML code, or copy and paste HTML
source code into the editor.
\item Finally, click the \textbf{Save this} button \emph{OR} click the \textbf{Save
and then attempt to clean HTML} button. If you do not do this, your work
will not be saved.
\end{enumerate}
Once you've saved your page, you can click the \textbf{View} button to preview
your Content Page.


Index: loncom/html/adm/help/tex/Latex_Footer.tex
+++ loncom/html/adm/help/tex/Latex_Footer.tex

\end{document}

Index: loncom/html/adm/help/tex/Latex_Header.tex
+++ loncom/html/adm/help/tex/Latex_Header.tex
%% LyX 1.2 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[12pt,english]{article}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{geometry}
\geometry{verbose,letterpaper,tmargin=1.25in,bmargin=1in,lmargin=1in,rmargin=1in}\pagestyle{headings}
\usepackage{amsmath}
\usepackage{graphicx}

\makeatletter

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
\providecommand{\LyX}{L\kern-.1667em\lower.25em\hbox{Y}\kern-.125emX\@}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
 \usepackage{verbatim}
 \newenvironment{lyxcode}
   {\begin{list}{}{
     \setlength{\rightmargin}{\leftmargin}
     \raggedright
     \setlength{\itemsep}{0pt}
     \setlength{\parsep}{0pt}
     \normalfont\ttfamily}%
    \item[]}
   {\end{list}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\usepackage{floatflt}

\usepackage{babel}
\makeatother
\begin{document}


Index: loncom/html/adm/help/tex/Login_To_LON-CAPA.tex
+++ loncom/html/adm/help/tex/Login_To_LON-CAPA.tex

To begin using LON-CAPA, you first need to log in to your account on LON-CAPA.
Open your web browser and navigate to your local LON-CAPA URL. You will be
presented with a log in screen.
%
\begin{figure}
\begin{center}\includegraphics[  width=0.50\paperwidth]{login}\end{center}


\caption{\label{LON-CAPA Log in screen}LON-CAPA Log in screen }
\end{figure}


Fill in the Username and Password boxes with your information. Then press
the Login button. This will take you to your LON-CAPA User Roles menu.

\begin{description}
\item [Note:] Your Username and Password will be given to you by your system administrator.
Both are case sensitive, so make sure you type them with the correct case.
\end{description}

Index: loncom/html/adm/help/tex/Metadata_Description.tex
+++ loncom/html/adm/help/tex/Metadata_Description.tex

\index{Metadata}\label{What Is Metadata?}\emph{Metadata} is \emph{data about data}. Metadata can often be thought
of as a label on some bit of information that can be useful to people or
computer programs trying to use the data. Without metadata, the person or
computer trying to use the original information would have to just guess
what the original data is about. For instance, if you create a problem and
neglect to say in the title or subject of the problem what it is about, then
a human who wants to use that problem would have to read the problem itself
to see what it was about, which is much more difficult than just reading
a title. A computer trying to do the same thing would just be out of luck;
it is too stupid to understand the problem statement at all.

One example of metadata is the <title> of a web page, which usually shows
up in the title bar of the browser. That's information about the web page
itself, not actually part of the web page. People use the title information
when they bookmark a page, so they know what the page is. Search engines
use it as a clue about the content of the web page.


Index: loncom/html/adm/help/tex/Numerical_Response_Advanced_Example.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Advanced_Example.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{numericalResponseSlopeProblem}\end{center}


\caption{Slope Problem Parameters\label{Slope Problem Parameters Figure}}
\end{figure}
 Try filling out your problem with the parameters shown in the ``Slope
 Problem Parameters'' figure. 

When creating randomized problems, you want to make sure that the problems
always have an answer. Consider what might happen if I had chosen the two
slopes \emph{both} with the expression \texttt{\&random(-1.0,1.0,.2)}. One
out of ten students would get a problem where both slopes were equal, which
has either no solution (for unequal y-intercepts) or an infinite number of
solutions (for equal slopes and y-intercepts). Both of these cause a division-by-zero
error on the division that computes the answer. There are many ways to avoid
this, one of the easiest of which is picking one slope negative and one positive.
This same problem can show up in many other places, too, so be careful.

Index: loncom/html/adm/help/tex/Numerical_Response_Format.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Format.tex
You can format the number displayed by the computer as the
answer. For instance, if the answer is one-third, the computer will display
that it computed {}``.333333333'' as the answer. If you'd like to shorten
that, you can use the \textbf{Format} field. Format strings like {}``2E''
(without the quotes) will display three significant digits in scientific
notation. Format strings like {}``2f'' will display two digits after the
decimal point.


Index: loncom/html/adm/help/tex/Numerical_Response_Intro.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Intro.tex

Along with showing the Numerical Response editor, figure \ref{Numerical Response Editor Figure}
also shows the parameters for one of the simplest possible types of numerical
response. The \textbf{Text Block} has the problem's question, which is the
static text {}``What is 2 + 2?'' The \textbf{Answer} is {}``4''. The
\textbf{Hint} has been set to something appropriate for this problem. Everything
else has the default values from when the problem was created.

If you create a problem like this, hit \textbf{Submit Changes}, then hit
\textbf{View} after the changes have been submitted, you can try the problem
out for yourself. Note the last box in the HTML page has the answer LON-CAPA
is looking for conveniently displayed for you, along with the range the computer
will accept and the number of significant digits the computer requires when
viewed by an \textbf{Author}.

As you're playing with the problem, if you use up all your tries or get the
answer correct but wish to continue playing with the problem, use the \textbf{Reset
Submissions} button to clear your answer attempts. 


Index: loncom/html/adm/help/tex/Numerical_Response_Introduction.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Introduction.tex

\index{Numerical Response}\label{Numerical Response}
Numerical Response problems are very powerful. In fact, they are so powerful
it would be impossible to fully explain what is possible in a simple document. 
This chapter will focus on getting you started with Numerical Response
problems, and showing you some of the possibilities, with no prerequisite
knowledge necessary. The more you learn, the more you will find you can do.

If you like, you can follow this chapter along as its own tutorial. Create
a Numerical Response problem using the instructions in section \ref{Creating New Content Pages},
ending your resource name with {}``.problem'', and create a new \textbf{Simple
Numerical Response} problem.

Index: loncom/html/adm/help/tex/Numerical_Response_Parts_A.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Parts_A.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{numericalResponse1}\end{center}


\caption{Numerical Response editor \label{Numerical Response Editor Figure}}
\end{figure}
A Numerical Response problem has seven major parts by default:

\begin{enumerate}
\item The \textbf{Script}. The script is the heart of advanced Numerical Response
problems. It can be used to decide some of the parameters of the problem,
compute the answer to the problem, and do just about anything else you can
imagine. The Script language is \textbf{Perl}. You do not need to know Perl
to use the \textbf{Script} block, as we will be stepping through some advanced
examples in this chapter, but knowing Perl can help.
\item Like other problem types, the \textbf{Text Block} is used to display the
problem the student will see. In addition, you can place variables in the
\textbf{Text Block} based on computations done in the \textbf{Script}.
\item The \textbf{Answer} is the answer the system is looking for. This can also
use parameters from the \textbf{Script} block, allowing the answer to be
computed dynamically.
Index: loncom/html/adm/help/tex/Numerical_Response_Parts_B.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Parts_B.tex
\item The \textbf{Single Line Text Entry} area, as in other problem types, allow you
to manipulate the text entry area the student will see.
\item Finally, the \textbf{Hint} should contain text which will help the students
when they answer incorrectly.
\end{enumerate}

Index: loncom/html/adm/help/tex/Numerical_Response_Problems.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Problems.tex

\textbf{Numerical Response\index{Numerical Response}} problems are answered
by entering a number and (optionally) a unit, such as 2.5 m/s\textasciicircum{}2.
Tolerance and required significant digits can be specified as well.


Index: loncom/html/adm/help/tex/Numerical_Response_Randomization.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Randomization.tex

For LON-CAPA, one of the most important functions is the \texttt{random}
function. Random takes three parameters: a \emph{lower limit}, an \emph{upper
limit}, and an \emph{interval}. The \texttt{\&random} function returns a
random value between the upper and lower limit, some integer number of \emph{interval}'s
away from the lower limit. Thus, for example, \texttt{\&random(1,2,.2)} might
return 1, 1.2, 1.4, 1.6, 1.8, or 2. \texttt{\&random} uses a uniform distribution.
Other distributions are available in LON-CAPA, and can be found by consulting
the function list.

%
\begin{figure}
\begin{lyxcode}
\$a~=~\&random(1.0,10.0,1.0);

\$b~=~\&random(-10.0,~-3.0,~1.0);

\$answer~=~\$a+\$b;
\end{lyxcode}

\caption{Sample \texttt{random} Calls \label{Sample Random Calls figure}}
\end{figure}
If you put the script in ``Sample Random Calls'' into the
\textbf{Script} block (replacing whatever contents might be in the block
already), you'll get two random variables \$a and \$b. Now, in the \textbf{Text
Block}, put {}``What is \$a plus \$b?'', and in the \textbf{Answer} put
{}``\$answer'', without the quotes for either of them. (It is a good idea
to create a variable to hold the answer and call it \$answer, or some other
reasonably standard name. Do not try to compute the answer in the \textbf{Answer}
field itself; it will not work as you expect.) Now save the problem and \textbf{View}
it. You'll see a randomized problem.

For each student, the same random number will be used each time they visit
the problem, but each student will get different random numbers. For any
but the simplest random problems, you'll want to see several random problems
to make sure everything is working out correctly. This is what the \textbf{Random
Seed\index{Random Seed}} field is for. To see another randomized version
of the problem you've just created, put another number into the \textbf{Random
Seed} field and hit \textbf{Change}. It doesn't really matter what number
you put into the field. But for any given \textbf{Random Seed} with the same
problem, you'll see the same randomized problem generated for you. (If you
change the \textbf{Script}, you are no longer guaranteed to get the same
problem.) 

Index: loncom/html/adm/help/tex/Numerical_Response_Simple_Example.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Simple_Example.tex

A script consists of several \textbf{statements}, separated by \textbf{semi-colons}.
A \textbf{statement\index{statement}} is the smallest kind of instruction
to the computer. Most problems will be built from several statements. 

A script can contain \textbf{comments}, which are not interpreted as statements
by the computer. Comments start with \textbf{\#}, and go to the end of that
line. Thus, if a line starts with \#, the whole line is ignored. Comments
can also begin in the middle of a line. It is a good idea to comment more
complicated scripts, as it can be very difficult to read a large script and
figure out what it does. It is a \emph{very} good idea to adopt some sort
of commenting standard, especially if you are working in a group or you believe
other people may use your problems in the future.

\begin{itemize}
\item One of the simplest statements in LON-CAPA is a \textbf{variable assignment}.
A \textbf{variable} can hold any value in it. The variable name must start
with a \textbf{\$}. In the \textbf{Script}, you need to assign to variables
before you use them. Put this program into the \textbf{Script} field of the
Numerical Response:

\begin{lyxcode}
\$variable~=~3;
\end{lyxcode}
This creates a variable named \textbf{variable} and assigns it the value
of {}``3''. That's one statement.

\end{itemize}
Variable names are \emph{case sensitive}, must start with a letter, and can
only consist of letters, numbers, and underscores. Variable names can be
as long as you want. 

Index: loncom/html/adm/help/tex/Numerical_Response_Tutorial_A.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Tutorial_A.tex

If you \textbf{Submit Changes} and \textbf{View} the problem, you'll see
nothing has changed. That's because in order for a variable to be useful,
it must be used. The variable can be used in several places.

Index: loncom/html/adm/help/tex/Numerical_Response_Units.tex
+++ loncom/html/adm/help/tex/Numerical_Response_Units.tex

Numerical Response problems can require units. In the problem editing form,
place the desired unit in the \textbf{Unit} field. For information about
what units the system accepts, see http://capa4.lite.msu.edu/demolibrary/Links/UnitsSymbolsT2.html.
The computer will accept the answer in any of its accepted unit formats.
For example, if the answer to a problem is {}``1ft'', the computer will
accept {}``12in'' as correct.

Index: loncom/html/adm/help/tex/Option_Response_Concept_Group_Example.tex
+++ loncom/html/adm/help/tex/Option_Response_Concept_Group_Example.tex

Example: A Concept Group may contain the following True/False questions:

\begin{itemize}
\item {}``Mark Twain'' is the pen name of Samuel Clemens.
\item Mark Twain wrote {}``The Call of the Wild''.
\item Mark Twain wrote {}``Huckleberry Finn''.
\item Mark Twain spent most of his life in the Congo.
\end{itemize}
For each foil, the author marks it True or False. When the student logs on
and attempts to answer this question, the student will see only one of the
four choices for that concept group. They then go on to do the remaining
three to seven Concept Groups in this question before submitting their answer.


Index: loncom/html/adm/help/tex/Option_Response_Matching_Example.tex
+++ loncom/html/adm/help/tex/Option_Response_Matching_Example.tex

Option Response problems can be used as matching problems.

For example, you might want to ask the student to match musical compositions
with their composers. You could create an Option Response problem with 4
Concept Groups, and place the following four foil groups each in its own
concept group:

\begin{itemize}
\item Claire de Lune\index{Clair de Lune}, Ballade (Debussy)
\item The Pastoral Symphony, The Ninth Symphony (Beethoven)
\item Sleeping Beauty Suite, The Dance of the Sugar Plum Fairies (Tchaikovsky)
\item Slavonic Dances, New World Symphony (Dvorak)

\end{itemize}
You could then add the following options to the option list:

\begin{itemize}
\item Debussy
\item Beethoven
\item Schubert
\item Tchaikovsky
\item Dvorak
\end{itemize}
The same answers can be used more then once, or not at all, as you see fit.
It is conventional to place such a warning in the \textbf{Text Block} describing
the problem to the students.


Index: loncom/html/adm/help/tex/Option_Response_Problem_Creation.tex
+++ loncom/html/adm/help/tex/Option_Response_Problem_Creation.tex

To create an Option Response problem, create a new resource as described
in section \ref{Creating New Content Pages}. This is a {}``problem'' resource
so the URL must end in {}``.problem''. You should see a screen as in
figure ``Option Response Editor''.

\begin{enumerate}
\item In the drop-down option box as seen in figure \ref{Creating a new problem resource},
select \textbf{Option Response Problem with} \textbf{\emph{N}} \textbf{Concept
Groups}, where \textbf{\emph{N}} is the number of Concept Groups you wish
the problem to have, and click the \textbf{New Problem} button.
\item Click the \textbf{Edit} button above the sample problem to enter edit mode.%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{optionResponseEditing}\end{center}


\caption{Option Response Editor\label{Option Response Editor Figure}}
\end{figure}
 You should see the Option Response page open up.
\item Replace the text in the \textbf{Text Block} with text that explains the conditions
for your problem.
\item Locate the \textbf{Max Number of Shown Foils} element and type a number from
1 to 8 to display that number of questions. You cannot display more than
one foil from each concept group, so this option will only reduce the number
of foils displayed, if it is less than the number of concept groups in your
Option Response problem.
\item Now you must define the options the students can select. For each option
you wish to add to the Option Response question, type the option into the
\textbf{Add new Option} box in the \textbf{Select Options} section, then
hit the \textbf{Save Changes} button. If you do not hit the \textbf{Save
Changes} button, your option will not be selectable below. (You will delete
unwanted options in the last step.)
\item Now, you need to define the question foils. Look for the foil with the name
{}``One''. Type the question into the text box, and select the correct
option for that question from the \textbf{Correct Option} drop-down menu.
Click \textbf{Submit Changes} to save this question foil. Repeat this step
for all remaining foils.
\item Locate the foils that are not being used. In their \textbf{Delete} menus,
set the value to \textbf{Yes}. Once you've set the Delete menu value correctly
for all the foils, click the \textbf{Save Changes} button.
\item In the Hint area, provide a helpful hint for users who get the problem incorrect,
and click the \textbf{Save Changes} button.
\item Make sure all the options you want to delete are not used for any of your
foils. If a deleted option is used in a foil, it will appear in a text box in the
\textbf{Correct Option} area for that foil. To make the drop-down box reappear,
type an option already defined in the \textbf{Select Options} field, and
hit \textbf{Submit Changes}. A drop-down box will reappear.
To delete the irrelevant options from the Option Response question, select
that option from the \textbf{Delete an Option} drop down, and hit the \textbf{Save
Changes} button. Do that for each option you wish to remove.
\end{enumerate}

Index: loncom/html/adm/help/tex/Option_Response_Problem_Figure.tex
+++ loncom/html/adm/help/tex/Option_Response_Problem_Figure.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{optionResponseProblem}\end{center}


\caption{Option Response Problem\label{Option Response Problem Figure}}
\end{figure}
Index: loncom/html/adm/help/tex/Option_Response_Problem_Parts.tex
+++ loncom/html/adm/help/tex/Option_Response_Problem_Parts.tex

Each Option Response problem can have three parts:

\begin{enumerate}
\item The Concept Groups\index{Concept Groups}
\item The options for the students to select, by default {}``True'' and {}``False''
\item The hint for the student
\end{enumerate}
Each \textbf{Concept Group} has some number of foils representing questions
which are conceptually related. Option Response Problem Templates are available
for 4 and 8 Concept Groups. When the Option Response problem is presented
to a student, the LON-CAPA system will randomly select one foil from each
Concept Group and present it to the student. In order to receive credit for
the problem, the student must select the corresponding option from the drop-down
box for each given foil.


Index: loncom/html/adm/help/tex/Option_Response_Problems.tex
+++ loncom/html/adm/help/tex/Option_Response_Problems.tex
\index{Option Response}\textbf{Option Response} problems present foils to the student with drop-down
boxes. The student can select the matching choice for the foils from a list
of choices. Optionally, the foils may be bundled into Concept Groups, and
the system will select one foil from each displayed group to display to the
student.

Index: loncom/html/adm/help/tex/Option_Response_Simple.tex
+++ loncom/html/adm/help/tex/Option_Response_Simple.tex

If you select \textbf{Simple Option Response} from the drop-down box, you
get a template that will allow you to enter up to eight foils with no grouping.
The system will randomly mix these foils when presenting them to the student.
You can have more foils then the \textbf{Max Num of Shown Foils} so that
each student will not have the identical foils.


Index: loncom/html/adm/help/tex/Problem_Editor_Testing_Area.tex
+++ loncom/html/adm/help/tex/Problem_Editor_Testing_Area.tex

The problem editor gives you a testing area where you can try your problems
out, with several different randomizations by varying the \textbf{Random
Seed}. If you answer a problem correctly and can no longer enter new answers,
you can get the answer field back by hitting the \textbf{Reset Submissions\index{Reset Submissions}}
button.

Index: loncom/html/adm/help/tex/Problem_Types.tex
+++ loncom/html/adm/help/tex/Problem_Types.tex

In this manual we will cover five basic types of problems: Radio Response,
Option Response, String Response, Numerical Response, and Formula Response.
You will need to identify which types of problem you want to use and create
appropriate questions for your course.

Index: loncom/html/adm/help/tex/Publishing_A_Resource.tex
+++ loncom/html/adm/help/tex/Publishing_A_Resource.tex



\index{Resource, Publishing}\index{Publishing Resource}

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{constructionSpaceForPublishing}\end{center}


\caption{Construction Space for Publishing\label{Construction Space for Publishing Figure}}
\end{figure}
To publish a resource, log in and choose your role to be an Author. Then
click \textbf{CSTR} to go to your construction space. You should see something
like the ``Construction Space for Publishing''. Click on the
\textbf{Publish} button for the resource you wish to publish.%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{publishMetadata}\end{center}


\caption{Publishing Metadata Screen\label{Publishing Metadata Screen Figure}}
\end{figure}
 You'll get a metadata screen that should look something like
the  ``Publishing Metadata Screen'' figure.
Fill out the form. If you are creating resources that may be used in several
courses, you should talk with the other authors and establish some sort of
standard title and subject scheme in advance. 

The \textbf{Language} is the language the problem is written in. The \textbf{Publisher/Owner}
is the LON-CAPA user who owns the problem.

The \textbf{Keywords} and the \textbf{Abstract} are more information about
the problem. The \textbf{Keywords} are words that are strongly connected
to your problem; for instance a physics problem about a pulley might include
{}``pulley'' as a key word. LON-CAPA pulls out words used in the text of
the resource for you so you can just click on their check boxes to make them
keywords. \textbf{Additional keywords} allows you to add any keyword to your
problem that are not actually in the problem. For instance, on that same
problem a physicist might add the keyword {}``statics'', even though it
doesn't appear in the original problem, because Physics uses that as a classification
of problem type. \textbf{Additional Keywords} are also useful when publishing
graphics.

Finally, you need to set the copyright and distribution permissions in the
\textbf{COPYRIGHT/DISTRIBUTION} drop-down. This setting controls who is allowed
to use your resource as follows:

\begin{itemize}
\item \textbf{Limited to courses in the domain published} means that only courses
running in the same domain as you can use your content. Talk to your LON-CAPA
administrator if you want more information about your domain.
\item \textbf{Free} means that anyone can find and use the resource.
\item \textbf{Private - visible to author only} means that it can't be used for
any course.
\item \textbf{Public - no authentication required} means anyone can find and use
the resource.
\end{itemize}
Now when you click \textbf{Finalize Publication}, your resource will be published
and usable (unless you set the distribution to {}``private'').

Index: loncom/html/adm/help/tex/Publishing_Author_Tutorial_Segue.tex
+++ loncom/html/adm/help/tex/Publishing_Author_Tutorial_Segue.tex
If you're following this as a tutorial, publish your resources so we can
use them in the next section.

Index: loncom/html/adm/help/tex/Publishing_Intro.tex
+++ loncom/html/adm/help/tex/Publishing_Intro.tex

In order to make the content you've created available for use in courses,
you must publish your content. LON-CAPA provides an easy interface for publishing
your content pages, problem resources, and sequences. You can specify title,
author information, keywords, and other metadata. LON-CAPA uses this metadata
for many things, and it's important to fill the metadata out as accurately
as possible.

Index: loncom/html/adm/help/tex/Radio_Response_Problems.tex
+++ loncom/html/adm/help/tex/Radio_Response_Problems.tex
\index{Radio Response}\textbf{Radio Response} problems present a list
of foils, with buttons in front. The student can select \emph{one} of
these statements by clicking the appropriate radio button.


Index: loncom/html/adm/help/tex/Radio_Response_Randomization.tex
+++ loncom/html/adm/help/tex/Radio_Response_Randomization.tex

LON-CAPA will randomize what choices are presented to each student, and randomize
the order they are presented in. If you wish to present each student the
same choices, make sure the \textbf{Maximum Number of Shown Foils} box contains
the number of incorrect answers, which will force them to all be displayed.



Index: loncom/html/adm/help/tex/Resource_Types.tex
+++ loncom/html/adm/help/tex/Resource_Types.tex

LON-CAPA provides three types of resources for organizing your course website.
LON-CAPA refers to these resources as Content Pages, Problems, and Maps.
Maps may be either of two types: Sequences or Pages. You will use these LON-CAPA
resources to build the outline, or structure, for the presentation of your
course to your students.

\begin{itemize}
\item A \textbf{Content Page}\index{Content Page} displays course content. It
is essentially a conventional HTML page. These resources use the extension
{}``.html''.
\item A \textbf{Problem}\index{Problem} resource represents problems for the students
to solve, with answers stored in the system. These resources are stored in
files that must use the extension {}``.problem''.
\item A \textbf{Sequence}\index{Sequence} is a type of \textbf{Map}\index{Map}
which is used to link other resources together. The users of this resource
can use directional buttons on their remote or the NAV button to follow the
sequence. Sequences are stored in files that must use the extension {}``.sequence''.
Sequences can contain other sequences and pages.
\item A \textbf{Page}\index{Page} is a type of \textbf{Map\index{Map}} which
is used to join other resources together into one HTML page. For example,
a page of problems will appears as a problem set. These resources are stored
in files that must use the extension {}``.page''.
\end{itemize}

Index: loncom/html/adm/help/tex/Script_Tutorial_Intro.tex
+++ loncom/html/adm/help/tex/Script_Tutorial_Intro.tex

Totally static problems only scratch the surface of the Numerical Response
capabilities. To really explore the power of LON-CAPA, we need to start creating
dynamic problems. But before we can get to truly dynamic problems, we need
to learn how to work with the \textbf{Script\index{Script}} window.

Index: loncom/html/adm/help/tex/Scripting_Help.tex
+++ loncom/html/adm/help/tex/Scripting_Help.tex

The full power of Perl is well outside the scope of this document. Looking
in the function list at \\
http://mileva.lite.msu.edu/loncapadocs/homework/homework5.html \\
can give you some ideas. O'Reilly has some good Perl books. The Perl 5 Pocket
Reference will contain more than what you need to know to use LON-CAPA, available
at \\
http://www.oreilly.com/catalog/perlpr3/ .

If you have any problems, consult http://help.loncapa.org/fom/cache/5.html
. If you don't find the answer to your problem, please help us expand the
FAQ by submitting a new pending question.

Our advanced users often come to prefer the XML interface for the problems,
available through the \textbf{EditXML} buttons. Covering the XML format is
beyond the scope of this manual, but you can learn a lot by using the editor
to make changes and seeing what happens to the XML.

Index: loncom/html/adm/help/tex/Sequence_Advanced_Editor_Creation.tex
+++ loncom/html/adm/help/tex/Sequence_Advanced_Editor_Creation.tex

After creating a new .sequence resource and getting the editor selection
prompt (\ref{Map Editor Selection Figure}), click the \textbf{Advanced
Edit} button to get to the advanced map editor. %
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{mapAdvancedEditorNew}\end{center}


\caption{Initial Map Editor\label{Initial Map Editor FIgure}}
\end{figure}
You should see the initial map editor as shown in the ``Initial Map Editor'' figure.
Note there are two windows: One is the workspace, and one is a secondary
window which will contain information as you add resources.

\begin{enumerate}
\item %
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{mapClickedStart}\end{center}


\caption{After clicking \textbf{Start} in the Map Constructor\label{Clicked Start Figure}}
\end{figure}
Click the \textbf{Start} box. You'll see what you see in the ``After
clicking \textbf{Start} in the Map Constructor'' figure.
Click \textbf{Link Resource} in the secondary window, then click on the \textbf{Finish}
box.%
\begin{figure}
\begin{center}\includegraphics[  height=0.25\paperwidth]{mapStraightened}\end{center}


\caption{Straightened Map\label{Striaghtened map}}
\end{figure}
 After that, click \textbf{Straighten}. You should see something
 looking like the ``Straightened Map'' figure. 
This creates a simple map that flows from beginning
to end.
\item %
\begin{figure}
\begin{center}\includegraphics[  height=0.30\paperwidth]{mapInsertResource}\end{center}


\caption{Inserting a Resource\label{Inserting a Resource Figure}}
\end{figure}
To insert a resource into the flow, click the black line with two arrows,
seen between the \textbf{Start} and \textbf{Finish} boxes in the
``Straigtened Map'' figure.
In the secondary window, you'll see something like the ``Inserting a
Resource'' figure.
Click \textbf{Insert Resource Into Link}. A new resource box will appear
in the link. Click the resource, which will have the label \textbf{Res}.
\item Click \textbf{Browse}, and the \textbf{Network Directory Browser} will appear,%
\begin{figure}
\begin{center}\includegraphics[  width=0.60\paperwidth]{mapEditorDirectoryBrowser}\end{center}


\caption{Network Directory Browser\label{Map Editor Network Directory Browser Figure}}
\end{figure}
 looking something like the ``Network Directory Browser'' figure.
Press the \textbf{SELECT} button that is next to the resource you want to
place in the chosen resource box.%
\begin{figure}
\begin{center}\includegraphics[  height=0.30\paperwidth]{mapEditorResourceChosen}\end{center}


\caption{Resource Chosen\label{Map Resource Chosen Figure}}
\end{figure}
 Once you've done that, if you look back at the window that popped up when
you clicked on \textbf{New Resource}, you'll see something like the
``Resource Chosen'' figure.
You can type the \textbf{URL} and \textbf{Title} into the secondary window,
if you prefer, following the format you see when you've successfully browsed
to a resource. After you click \textbf{Save Changes}, your changes will be
set, and the icons for the resource will appear in the \textbf{Res} box,
as shown in figure \ref{Map Resource Chosen Figure}. Click \textbf{Save
Map} in the bar above your map to save the map.


Clicking on the left icon for a resource will open a new browser window with
an informational page about that resource. Clicking on the right icon for
a resource will open a new browser window taking you to the rendering of
that resource.

\item Repeat steps two and three for as many resources as you'd like to bind together
into one page. You can insert the new resources anywhere you'd like.
\item When you are done adding resources, click the \textbf{Save Map} link to save
the map.
\end{enumerate}
In addition to manually adding in resources, the Advanced Editor also has
the ability to import resource in the same way that the Simple Editor can:
>From a LON-CAPA network browser window, from a Group Search, or from another
Map.

The advanced editor has many more capabilities which you can explore.


Index: loncom/html/adm/help/tex/Sequence_Definition.tex
+++ loncom/html/adm/help/tex/Sequence_Definition.tex

\index{Sequence}

A \textbf{Sequence} is a series of resources that can be navigated using
the \textbf{NAV} remote control button, or by using the arrow keys on the
remote control. 

Index: loncom/html/adm/help/tex/Sequence_Editor_Selection.tex
+++ loncom/html/adm/help/tex/Sequence_Editor_Selection.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.40\paperwidth]{mapEditorSelection}\end{center}


\caption{Map Editor Selection\label{Map Editor Selection Figure}}
\end{figure}
To create a Sequence resource, create a new resource as described in section
\ref{Creating New Content Pages}. This is a {}``sequence'' resource so
the URL must end in {}``.sequence''. After you enter in the URL ending
in {}``.sequence'', you should see a screen as in figure \ref{Map Editor Selection Figure}.
You can use either the advanced editor or the simplified editor.


Index: loncom/html/adm/help/tex/Sequence_Page_Maps.tex
+++ loncom/html/adm/help/tex/Sequence_Page_Maps.tex

Creating a .page map is the same as creating a sequence map, except that
when choosing the name of the resource, the URL will end with {}``.page''.
Then all resources you add in the map editor will appear on one page together.

Pages are often used to connect problems in a homework set.

Index: loncom/html/adm/help/tex/Sequence_Simple_Editor_Creation.tex
+++ loncom/html/adm/help/tex/Sequence_Simple_Editor_Creation.tex

%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{mapSimpleEditor}\end{center}


\caption{Simple Map Editor\label{Simple Map Editor}}
\end{figure}
After creating a new .sequence resource and getting the editor selection
prompt (as in the ``Simple Map Editor'' figure), click the \textbf{Simple
Edit} button to get to the simple map editor, which appears in the figure. 

The Simple Editor can create .sequences and .pages which are linear, which
means they have no branches or conditions.

On the right side of the simple editor is the \textbf{Target}, which represents
the map you are currently building. On the left side is the \textbf{Import}
area, which represents a work area you can use for your convenience to load
and manipulate resource you may wish to include in your map. Using the three
buttons in the middle of the screen, from top to bottom you can cut things
out of the Target, copy from the Target to the Import, and copy from the
Import to the Target, respectively.

On both sides of the screen, you can do a Group Search and a Group Import.
A Group Search allows you to run a search, then import selected results from
that search into either directly into your Map, or into your Import space.
Checkboxes will appear next to the results in the Group Search, and you can
click the resource you wish to add to your map in the order that you want
them added. After you select the resource, you will be presented with a screen
that allows you to change the order of the selected resources, then you will
be able to import the selected resources and work with them.

A Group Import works in a similar fashion, but allows you to use the LON-CAPA
network browser to select your resources.

On the Import side, you can also browse for another Map, and load the resources
used in that map into your Import workspace. You can also discard the selected
resources, clear all the resources, and view the selected resource from the
buttons on the Import side of the screen. 

Both list boxes support standard multi-select mechanisms as used in your
OS.

Index: loncom/html/adm/help/tex/Sequence_Top-Level.tex
+++ loncom/html/adm/help/tex/Sequence_Top-Level.tex

In order to view sequences, they need to be part of a \textbf{course}.

%
\begin{figure}
\begin{center}\includegraphics[  width=0.40\paperwidth]{creatingANewCourse}\end{center}


\caption{Creating a New Course\label{Creating a New Course Figure}}
\end{figure}
 Courses have a Top-level Map which defines the whole course. This top-level
map will often itself contain maps corresponding to homework assignments,
chapters, or units. To view your maps, you will need to make them part of
a course. Only Domain Coordinators can make courses and set their Top-level
maps, so work with your Domain Coordinator if you need to view your maps.


Index: loncom/html/adm/help/tex/Significant_Figures.tex
+++ loncom/html/adm/help/tex/Significant_Figures.tex
A \textbf{significant figures} specification tells the system how many significant
figures there are in the problem, as either a single number or a range of
acceptable values, expressed as \textbf{min,max}. The system will check to
make sure that the student's answer contains this many significant digits,
useful in many scientific calculations. For example, if the problem has three
significant digits, the significant digit specification is {}``3'', and
the answer is {}``1.3'', the system will require the students to type {}``1.30'',
even though numerically, {}``1.3'' and {}``1.30'' are the same. A significant
figure specification of {}``3,4'' means both {}``1.30'' and {}``1.300''
are acceptable.
Index: loncom/html/adm/help/tex/String_Response_Problem_Creation.tex
+++ loncom/html/adm/help/tex/String_Response_Problem_Creation.tex

To create a String Response problem, create a new .problem resource (described in
\ref{Creating New Content Pages}). This is a {}``problem'' resource
so the URL must end in {}``.problem''. 

\begin{enumerate}
\item In the drop-down option box as seen in \ref{Creating a new problem resource},
select \textbf{String Response Problem}, and click the \textbf{New Problem}
button.
\item Click the \textbf{Edit} button above the sample problem to enter edit mode.%
\begin{figure}
\begin{center}\includegraphics[  width=0.80\paperwidth]{stringResponseEditor}\end{center}


\caption{String Response Editor\label{String Response Editor Figure}}
\end{figure}
 You should see the String Response editor page open up, which should look
something like what you see in the ``String Response Editor'' figure.
\item Clear the text from the \textbf{Text Block} at the top of the problem, and
type in your problem.
\item In the \textbf{Answer Box}, type the correct answer.
\item Select the answer condition from the drop-down. There are three cases to
choose from:

\begin{enumerate}
\item \textbf{cs}: This means {}``Case Sensitive''. For example, this is useful
in chemistry, where HO and Ho are completely different answers. The student must match the case of the answer.
\item \textbf{ci}: This means {}``Case Insensitive''. The system does not use
the case of the letters to determine the correctness of the answer. If the
correct answer is {}``car'', the system will accept {}``car'', {}``CAR'',
{}``Car'', {}``caR'', etc.
\item \textbf{mc}: This means {}``Multiple Choice''. The student's answers must
contain the same letters as the question author's, but order is unimportant.
This is usually used to give a multiple choice question in the question's
\textbf{Text Block}, which may have several correct parts. If the author
sets the correct answer as {}``bcg'', the system will accept {}``bcg'',
{}``cbg'', {}``gcb'', etc., but not {}``bc'' or {}``abcg''.
\end{enumerate}
It is conventional to inform the students if the problem is case sensitive,
or that the order of the answers doesn't matter.

\item Optionally, locate the \textbf{Single Line Text Entry Area} block and set
a length in the Size box. This will only affect the size of the box on the
screen; if you set the box size to 2, the student can still enter 3 or more
letters in their answer.
\item Scroll down to the \textbf{Hint} element, and type some text that will help
students when they answer incorrectly, or delete the hint by setting the
\textbf{Delete} field to \textbf{Yes}.
\item Click the \textbf{Submit Changes} button.
\end{enumerate}

Index: loncom/html/adm/help/tex/String_Response_Problems.tex
+++ loncom/html/adm/help/tex/String_Response_Problems.tex

\textbf{\index{String Response}String Response} problems are problems in
which the student submits a string of characters for the answer. Examples
of string response questions are vocabulary tests, short answer and entering
chemical formulas.

Note that it is easy to abuse String Response problems. For instance, consider
the question {}``Who wrote 'Huckleberry Finn'?'' If you tell the system
the answer is {}``Mark Twain'', and a student answers {}``Twain'', the
system will mark it wrong. If they answer {}``Samuel Clements'', then the
student will definitely get it wrong. There is some room for flexibility
in the string processing, but it can be difficult to get it all right. Before
you use a String Response problem, be sure you can easily characterize correct
answers.


Index: loncom/html/adm/help/tex/Tolerance.tex
+++ loncom/html/adm/help/tex/Tolerance.tex
A \textbf{tolerance\index{tolerance}} parameter determines how closely
the system will require the student's answer to be in order to count it correct.


For technical reasons, it is almost never a good idea to set this parameter
to zero. Computers can only approximate computations involving real numbers. For instance,
a computer's {[}decimal{]} answer to the simple problem $\frac{1}{3}$ is
{}``0.33333333333333331''. It \emph{should} be an infinite series of 3's,
and there certainly shouldn't be a {}``1'' in the answer, but no computer
can represent an infinitely long, infinitely detailed real number. Therefore,
for any problem where the answer is not a small integer, you \emph{need}
to allow a tolerance factor, or the students will find it nearly impossible
to exactly match the computers idea of the answer. You may find the
default too large for some problems. 

There are
two kinds of tolerance. For some answer $a$ and a tolerance $t$,

\begin{enumerate}
\item an \textbf{Absolute} tolerance\index{absolute tolerance}\index{tolerance, absolute}
will take anything in the range $a\pm t$. So if $a=10$ and $t=2$, then
anything between 8 and 12 is acceptable.
 Any number in the tolerance field \emph{without} a \textbf{\%} symbol is
an absolute tolerance.
\item a \textbf{Relative} tolerance\index{relative tolerance}\index{tolerance, relative}
will take anything in the range $a\pm at$, where \emph{t} is interpreted
as a percentage. Any number in the tolerance field \emph{followed by} a \textbf{\%}
symbol is a relative tolerance. For example, $a=10$ and $t=10\%$ will accept
anything between 9 and 11. 
\end{enumerate}
Index: loncom/html/adm/help/tex/Variable_Naming_Conventions.tex
+++ loncom/html/adm/help/tex/Variable_Naming_Conventions.tex

There are many variable naming conventions, covering both how to name and
how to capitalize variables%
\footnote{The author favors \texttt{capsOnNewWords}. Some people use \texttt{underscore\_to\_separate\_words}.
Many use uppercase letters to specify constants like \texttt{PI} or \texttt{GOLDEN\_MEAN}.
Some people always \texttt{StartWithCapatalization}. What's really important
is to be consistent, so you don't have to guess whether the variable you're
thinking of is \texttt{coefFriction}, \texttt{CoefFriction}, \texttt{COEF\_FRICTION},
or something else.%
}. It is a good idea to adopt a standard. If you are working with a group,
you may wish to discuss it in your group and agree on a convention. 

Index: loncom/html/adm/help/tex/Variable_Tutorial_A.tex
+++ loncom/html/adm/help/tex/Variable_Tutorial_A.tex

If you are following this chapter as a tutorial, add the previous two lines
to your \textbf{Script} and submit the changes for the problem. There's no
need to view it; there's still no visible change.


Index: loncom/html/adm/help/tex/Variables_in_Scripts.tex
+++ loncom/html/adm/help/tex/Variables_in_Scripts.tex

Variables can be used later in the same script. For instance, we can add
another line below the \texttt{\$variable} line as such:

\begin{lyxcode}
\$variable2~=~\$variable~+~2;
\end{lyxcode}

Now there is a variable called \texttt{\$variable2} with the the number {}``5''
as its value. 

Variables can also be used in \emph{strings}\index{strings}, which are a
sequence of letters. The underlying language of the script, Perl, has a very
large number of ways of using variables in strings, but the easiest and most
common way is to use normal double-quotes and just spell out the name of
the variable you want to use in the string, like this:

\begin{lyxcode}
\$stringVar~=~{}``I~have~a~variable~with~the~value~\$variable.''
\end{lyxcode}

This will put the string {}``I have a variable with the value 3.'' into
the variable named {}``stringVar''.

Index: loncom/html/adm/help/tex/Variables_in_the_Answer_Block.tex
+++ loncom/html/adm/help/tex/Variables_in_the_Answer_Block.tex

You can use variables in the \textbf{Answer} part of the question, too. This
means you can compute an answer to a question, which we'll see in a bit.
If you set the answer of the question to be \textbf{\$variable}, \textbf{Save
Changes} and \textbf{View} it, you'll see that LON-CAPA is now expecting
{}``3.0'' as the answer, plus or minus 5\%.

Index: loncom/html/adm/help/tex/Variables_in_the_Text_Block.tex
+++ loncom/html/adm/help/tex/Variables_in_the_Text_Block.tex

Once you've defined variables in the \textbf{Script}, you can use them in
the \textbf{Text Block}. For example, using the previous three-line script
we've created so far, you can place the following in the \textbf{Text Block}:

\begin{lyxcode}
See~the~3:~\$variable<br~/>

See~the~string:~<b>\$stringVar</b><br~/>
\end{lyxcode}
%
\begin{figure}
\begin{center}\includegraphics{numericalResponseVarInText}\end{center}


\caption{Result of Variables in the Text Block\label{Result of Variables in the Text Block Figure}}
\end{figure}
If you save that and hit \textbf{View}, you should get what you see in figure
\ref{Result of Variables in the Text Block Figure}. Note how the {}``\$variable''
was turned into a 3, and the {}``\$stringVar'' was turned into {}``I have
a variable with the value 3.''


Index: loncom/interface/lonhelp.pm
+++ loncom/interface/lonhelp.pm
# The LearningOnline Network with CAPA
# .tex help system web server handler
#
# Copyright Michigan State University Board of Trustees
#
# This file is part of the LearningOnline Network with CAPA (LON-CAPA).
#
# LON-CAPA 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.
#
# LON-CAPA 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 LON-CAPA; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
#
# /home/httpd/html/adm/gpl.txt
#
# http://www.lon-capa.org/
#
# .tex file help handler
# YEAR=2002
# 7/4 Jeremy Bowers

package Apache::lonhelp;

use strict;
use Apache::Constants qw(:common :http);
use Apache::File;
use Apache::loncommon;
use tth;
use GDBM_File;

# This sub takes the name of a label in, and converts it to something
# that is a valid anchor name.
sub processLabelName 
{
    my ($name) = @_;
    $name =~ tr/a-zA-Z0-9/_/cs;
    return $name;
}

# Serve out the Tex
sub serveTex
{
    my ($tex, $r) = @_;

$r->print(<<HEADER);
<html>
    <head>
        <title>LON-CAPA Help</title>
    </head>
    <body bgcolor="#FFFFFF">
HEADER

    $r->print($tex);

$r->print(<<FOOTER);
    </body>
</html>
FOOTER
}

# Render takes a tex fragment, transforms it for TtH, and returns the
# HTML equivalent
sub render 
{
    my ($tex) = @_;
    tie (my %fragmentLabels, 'GDBM_File', '/home/httpd/html/adm/help/fragmentLabels.gdbm', 0, 0);

    # This tells TtH what to do with captions, labels, and other
    # things
    $tex = "\\documentclass{article}\n" . $tex;

    # We process these ourselves because TtH can't handle then without
    # LaTeX .aux files
    $tex =~ s|  \\ref\{([^}]*)\}
             |'\\href{' . 
              substr($fragmentLabels{$1}, 0, -4) .
              '#' . processLabelName($1) . 
             '}{graphic}'
             |gxe;

    # Figures leftover without captions
    $tex =~ s|  \\includegraphics(\[[^]]*\])*\{([^}]*)\}
             |  '\\begin{html}<img src="gif/' . $2 . '.gif" border="2"'.
                ' bordercolor="#000000"/>\\end{html}'
             |gxe;

    $tex = tth::tth($tex);

    # For some reason all captions come out as "Figure 0:", so
    # just duck the issue...

    $tex =~ s/Figure 0://g;

    untie %fragmentLabels;

    return $tex;
}

# UNCOMMENT FOR HANDLER ONLY
sub handler
{
     my $r = shift;

     my $filename = substr ($ENV{'REQUEST_URI'} , 
			    rindex($ENV{'REQUEST_URI'}, '/') + 1, -4);
     
     # Security check on the file; the whole filename must consist
     # of nothing but alphanums, ' ,, or ., or the file
     # will be "not found", no matter what.
     
     return 404 if ($filename !~ /\A[-0-9a-zA-z_'',.]+\Z/);

     (my $file = Apache::File->new("/home/httpd/html/adm/help/tex/".$filename.'.tex'))
	 or return 404;
     my $tex = join('', <$file>);
     $tex = render($tex);
     $r->content_type("text/html");
     serveTex($tex, $r);

     return OK;
}

1;

--bowersj21025885552--