home *** CD-ROM | disk | FTP | other *** search
/ CD Ware Multimedia 1999 March / CDW0399.iso / Demos / HomePage / data1.cab / Program_Executable_Files / Homepage.exe / 1009 / 2022 < prev    next >
Encoding:
Text File  |  1997-12-10  |  4.5 KB  |  103 lines

  1. ///////////////////////////////////////////////////////////////////////////
  2. // OScriptT.txt (VDL 2022)
  3. // AUTHOR: Anthony C. Ard <anthony_ard@claris.com>, 26-Jun-97.
  4. // Copyright 1997 Claris
  5. // Top half of the Object Editor for an HTML code object.
  6. #include "ObjEPref.txt"
  7. ///////////////////////////////////////////////////////////////////////////
  8. // LOCALIZED STRING CONSTANTS BEGIN
  9. /* This section contains all localizable string constants for this VDL
  10.    program. Be sure to include the backslash character at the end of each
  11.    line of a multi-line string, except for the last line.  You may also
  12.    flatten multiline constants into a single line, if you prefer. */
  13. #define kLit1 "Language:"
  14. #define kLitAutoScriptInfo "Enter your code below.  Claris Home Page will automatically enclose the code with Script tags."
  15. #define kLitOpenBracket "<SCRIPT LANGUAGE= "
  16. #define kLitEndBracket  " >   " //note: extra spaces are needed to tweak this VDL on Windows.
  17. #define kLitCloseScript "</SCRIPT>   "
  18. //Mouseover help
  19. #define kLit201 "Specifies the scripting language."
  20. #define kLit202 "Area for entering the script."
  21. //Localized Fonts
  22. #if Platform_Mac
  23.     #define kHelpFont         Font = {Geneva, 10, {Plain}}
  24.     #define kBoldFont        Font = {Geneva, 10, {Bold}}
  25.     #define kLabelBoldFont LabelFont = {Geneva, 10, {Bold}}
  26. #else
  27.     // Platform Windows
  28.     #if Dialog_Pixels == 100 //e.g. small fonts
  29.         #define kBoldFont       Font = {"MS Sans Serif", 8, {Bold}}
  30.         #define kHelpFont         Font = {"MS Sans Serif", 8, {Plain}}
  31.         #define kLabelBoldFont  LabelFont =  {"MS Sans Serif", 8, {Bold}}
  32.     #else                    // large fonts
  33.         #define kHelpFont         Font = {"MS Sans Serif", 6, {Plain}}
  34.         #define kBoldFont       Font = {"MS Sans Serif", 6, {Bold}}
  35.         #define kLabelBoldFont    LabelFont =  {"MS Sans Serif", 6, {Bold}}
  36.     #endif
  37. #endif
  38. ///////////////////////////////////////////////////////////////////////////
  39. // LOCALIZED STRING CONSTANTS END
  40. ///////////////////////////////////////////////////////////////////////////
  41. // LOCALIZED NUMERICAL CONSTANTS BEGIN
  42. /* This section contains integer constants that are used to format this VDL
  43.    program. These are localizable - they only need to be changed if the
  44.    localized strings are sufficiently longer than the US strings.  Localize
  45.    the strings first, then the constants. */
  46. #define kScriptEditLanguageWidth 200
  47. #define kScriptEditHeight 300
  48. #define kLabelWidth LabelWidth =60
  49. #if Platform_Win
  50.     #if Dialog_Pixels == 100 //e.g. Windows small fonts
  51.         #define kWidthScriptInfo 140
  52.         #define kWidthLanguage     80
  53.     #else // Windows: large fonts
  54.         #define kWidthScriptInfo 130
  55.         #define kWidthLanguage     80
  56.     #endif
  57. #else
  58. #define kWidthScriptInfo -1
  59. #define kWidthLanguage     -1
  60. #endif
  61. ///////////////////////////////////////////////////////////////////////////
  62. // LOCALIZED NUMERICAL CONSTANTS END
  63. // No further localizable data past this point.
  64. // END LOCALIZABLE DATA
  65. ///////////////////////////////////////////////////////////////////////////s
  66. VList( stdBackColor, Width = UseParent, Height = kScriptEditHeight ) 
  67. {
  68.     HList( Width = UseParent ) 
  69.     {
  70.         EditText( obj.language, Label = kLit1,kLabelWidth, Width = kScriptEditLanguageWidth,
  71.                      StdFlags, EH kLit201,kLabelBoldFont );
  72.         StdHSpace;
  73.         GenericView( "ScriptTypePopup" );
  74.     }
  75.     StdVSpace;
  76.     StaticText(kLitAutoScriptInfo, kPlainFont, Alignment = Left, Width = UseParent);
  77.     Spacer(Width=0, Height=7);
  78.     HList()
  79.     {
  80.         StaticText(kLitOpenBracket, kBoldFont, Width = kWidthScriptInfo);
  81.         StaticText(obj.language, kBoldFont,Alignment=Left, Width = kWidthLanguage);
  82.         StaticText(kLitEndBracket, kBoldFont);
  83.     }
  84.     StdVSpace;
  85.     VList( VScroll, BackColor = White,
  86.              Width = UseParent, Height = UseParent )
  87.         Margin( 2, 2, 2, 2 ) EditText( obj.contents, LabelWidth = 0,
  88.                                                  kEditFont, NoSmartQuotes,
  89.                                                  MultiLine, /*NoFrame,*/ 
  90.                                                  Width = UseParent,
  91.                                                  NoSmartEdits, EH kLit202 );
  92.     StdVSpace;
  93.     StaticText(kLitCloseScript, kBoldFont);
  94.     //jeh 10.18.97 took out "NoFrame", so user can see where it's ok to edit. Without
  95.     // this change, it looked like you could click anywhere to start editing when in fact
  96.     // only the very first line was active.
  97.     // Another possible solution is to remove MultiLine, adding Height = XXX instead.
  98.     // however, this might limit the length of the text edit field.
  99.     //Note: removing Margin(..) before the EditText solves the I-beam cursor problem, but
  100.     // still doesn't solve the problem of requiring user to click in exactly the first line.
  101. }
  102.  
  103.