ide: Renamed selection of 32/64 bit from 'bit depth' to 'bit length'; Updated credits
[sdk] / ide / src / about.ec
index c8d9bc6..306a42e 100644 (file)
@@ -6,7 +6,7 @@ import "ecere"
 
 import "licensing"
 
-#if /*defined(_W64) || */(defined(__WORDSIZE) && __WORDSIZE == 8) || defined(__x86_64__)
+#if (defined(__WORDSIZE) && __WORDSIZE == 8) || defined(__x86_64__)
 #define X64STRING " (64 bit)"
 #else
 #define X64STRING " (32 bit)"
@@ -16,16 +16,38 @@ class AboutIDE : Window
 {
    borderStyle = sizable;
    hasClose = true;
-   clientSize = { 440, 440 };
+   minClientSize = { 462, 440 };
    text = $"About the Ecere SDK";
    tabCycle = true;
 
-   Label { this, text = "Ecere Software Development Kit   v0.44.04 \"Ryōan-ji\"" X64STRING, font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 128 } };
-   Label { this, text = "Copyright © 2005-2013 Ecere Corporation",         font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 144 } };
-   Label { this, text = "Copyright © 1996-2013 Jérôme Jacovella-St-Louis", font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 160 } };
-   Label { this, text = $"Lead Architect and Developer", font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 188 } };
-   Label { this, text = "Jérôme Jacovella-St-Louis", position = { 220, 188 } };
-   Label { this, text = $"With contributions from...", font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 208 } };
+   EditBox versionCopyright
+   {
+      this, font = { $"Tahoma", 8.25f, bold = true }, borderStyle = none, background = white, readOnly = true, noCaret = true, multiLine = true, autoSize = true, position = { 13, 128 };
+   };
+
+   bool OnPostCreate()
+   {
+      char * longVersion = CopyString(REPOSITORY_VERSION);
+      char * shortVersion;
+      char * tokens[16];
+      char * message;
+      uint count;
+      StripQuotes(longVersion, longVersion);
+      count = TokenizeWith(longVersion, sizeof(tokens)/sizeof(tokens[0]), tokens, "-+", false);
+      shortVersion = count ? tokens[0] : longVersion;
+      message = PrintString(
+            "Ecere Software Development Kit v", shortVersion, " \"Ryōan-ji\"" X64STRING "\n"
+            "Build " REPOSITORY_VERSION "\n"
+            "Copyright © 2005-2014 Ecere Corporation\n"
+            "Copyright © 1996-2014 Jérôme Jacovella-St-Louis");
+      versionCopyright.contents = message;
+      delete message;
+      delete longVersion;
+   }
+
+   Label { this, text = $"Lead Architect and Developer", font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 194 } };
+   Label { this, text = "Jérôme Jacovella-St-Louis", position = { 220, 194 } };
+   Label { this, text = $"With contributions from...", font = { $"Tahoma", 8.25f, bold = true }, position = { 16, 214 } };
    Button licensingBtn
    {
       this, anchor = { left = 40, bottom = 10 }; hotKey = altL; text = "Software Licenses";
@@ -35,7 +57,7 @@ class AboutIDE : Window
          return true;
       }
    };
-   Button button 
+   Button button
    {
       this, text = $"OK", isDefault = true, size = { 80, 20 }, anchor = { right = 13, bottom = 10 };
 
@@ -47,11 +69,11 @@ class AboutIDE : Window
    };
    EditBox credits
    {
-      this, borderStyle = none, noCaret = true, readOnly = true, anchor = { left = 16, top = 236, bottom = 48, right = 16 },
+      this, borderStyle = none, noCaret = true, readOnly = true, anchor = { left = 16, top = 242, bottom = 48, right = 16 },
       background = { r = 250, g = 252, b = 255 };
       multiLine = true,
       hasVertScroll = true,
-      contents = 
+      contents =
          "Réjean Loyer\n"
          "   Most of the additional programming on the IDE\n"
          "   Initial EDA design\n"
@@ -60,7 +82,7 @@ class AboutIDE : Window
          "Niraj Kulkarni\n"
          "   EditBox fixes\n"
          "\n"
-         "Juan Sánchez\n"
+         "Juan Sánchez Rangel\n"
          "   Oracle EDA driver\n"
          "   Spanish translation\n"
          "   Finally getting us an IDE toolbar!\n"
@@ -161,7 +183,7 @@ class AboutIDE : Window
    //Label { this, text = "Max Maton", position = { 192, 204 } };
    Picture picture
    {
-      this, size = { 318, 94 }, position = { 64, 11 }, image = { ":ecere.jpg" };
+      this, size = { 318, 94 }, anchor = { top = 11 }, image = { ":ecere.jpg" };
       cursor = ((GuiApplication)__thisModule).GetCursor(hand);
 
       bool OnLeftButtonDown(int x, int y, Modifiers mods)