Skip to content

Commit a440b33

Browse files
authored
Merge pull request #1049 from cjakeman/docs-move-online
Re-organise document storage and access
2 parents 9295cb9 + 6a0c471 commit a440b33

12 files changed

+31
-1
lines changed
Binary file not shown.
-101 KB
Binary file not shown.
File renamed without changes.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
In Source\Documentation\ store the source files for documents useful in running Open Rails.
2+
These will be processed to PDF format which is distributed as part of the installation and available to users in the drop-down Menu > Documents
3+
4+
In Source\Documentation\Online store the source files for documents not used in running Open Rails.
5+
They should be MS Office or OpenOffice format and will be automatically processed to PDF format and stored on the website
6+
where they are available via a link in the drop-down.
7+
These include:
8+
- installation
9+
- translating
10+
- notifications
11+
- content creation
12+
- code-related
13+
- architecture
14+
15+
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
In Source\Documentation\ to store source for documents useful in running Open Rails.
2+
This applies to core Open Rails and also to non-core (or "contributed") programs.
3+
4+
They should be MS Office or OpenOffice format and will be processed to PDF format which is distributed as part of the installation and available to users in the drop-down Menu > Documents
5+
6+
Other documents should be stored in Source\Documentation\Online and these are all available on the website via a link in the drop-down.
7+

Source/Menu/MainForm.cs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ orderby tool.Text
243243
var docs = new List<ToolStripItem>();
244244
var dir = Directory.GetCurrentDirectory();
245245
var path = dir + @"\Documentation\";
246+
246247
if (Directory.Exists(path))
247248
{
248249
// Load English documents
@@ -259,7 +260,14 @@ orderby tool.Text
259260
LoadDocuments(docs, codePath, code);
260261
}
261262
}
262-
else buttonDocuments.Enabled = false;
263+
264+
var item = new ToolStripMenuItem($"Online documents (opens browser)", null, (object sender2, EventArgs e2) =>
265+
{
266+
Process.Start("https://www.openrails.org/learn/docs-list/");
267+
}
268+
);
269+
contextMenuStripDocuments.Items.Add(new ToolStripSeparator());
270+
contextMenuStripDocuments.Items.Add(item);
263271

264272
NotificationManager = new NotificationManager(this, this.Resources, UpdateManager, Settings, panelDetails);
265273
}

0 commit comments

Comments
 (0)