ReadMe for Myriarch 2.0.0

ProgramMyriarch for Java
Version2.0.0 (History)
Released18 June 2017
AuthorChristoph Nahr (Copyright)
Contactwebmaster@kynosarges.org
Websitekynosarges.org/Myriarch.html

Table of Contents

  1. System Requirements
  2. Package Contents
  3. Usage Overview
  4. Source Package
  5. Known Issues
  6. Copyright Notice

1. System Requirements

Myriarch is a JavaFX desktop application that should work on any system with a current Java Runtime Environment (JRE). The precompiled JAR file requires Oracle Java SE 8 Update 66 with JavaFX 8 or later. Older JREs that only support Swing will not work.

Some hyperlink actions rely on Java’s multiplatform support for invoking default applications, such as web browsers and mail clients. These should work on all desktop platforms, assuming your applications are properly configured to handle the desired URLs or file types. If some action is entirely unsupported on your platform, the hyperlink’s tool tip will state that fact.

Microsoft Windows — Please see Oracle Java on Windows for information on how to avoid Oracle’s inferior default Windows JRE. For Myriarch in particular, the non-default Server VM runs the simulation much faster than the default Client VM.

2. Package Contents

The directory to which the binary package was unpacked contains the following files:

Myriarch.jarMyriarch GUI executable
ReadMe.htmlThis file
WhatsNew.htmlMyriarch version history
project.cssStyle sheet for ReadMe & WhatsNew
help/*Myriarch help system (view index.html)
lib/Myriarch.Core.jarMyriarch core library & console runner
lib/Tektosyne.jarTektosyne library for computational geometry
scenario/*Simulation scenarios

These files are all you need to run Myriarch. Java programmers may also want to download the source package which is available separately.

3. Usage Overview

Use the command line javaw -jar Myriarch.jar to run Myriarch. Depending on your JVM, you may also be able to omit javaw -jar and directly execute Myriarch.jar directly, or to simply double-click on Myriarch.jar in your favorite file explorer.

For more information on how to run a simulation, please see the integrated help system (Help button, F1). Use New to start a new simulation. Currently only Leuctra 371 BC is available.

Myriarch creates a folder called Myriarch in the current user’s home directory to store saved simulations, as well as temporary files for the help system. If creation of that folder fails, Myriarch will attempt to store simulations directly in the current user’s home directory.

Known JavaFX Issues

There are currently two known JavaFX issues that might affect your system. First, its hardware accelerated graphics may cause some display drivers to crash; and second, its automatic DPI scaling is disabled by default on Windows at 120 DPI (125%) which might cause layout errors. Should you experience these issues you can avoid them using Java startup switches, as described here.

4. Source Package

The source package is available as a separate download on the Myriarch home page. The expected environment is NetBeans 8.2 with Oracle JDK 8u131. This package contains all of the files in the binary package, except for the precompiled Java archives, plus the following for each project:

build.xmlCustomized build steps
manifest.mfApplication manifest placeholder
nbproject/*NetBeans project configuration
dist/javadoc/*Javadoc class reference
src/*Source code and resources
test/*Unit tests where applicable

NetBeans injects custom dependencies into its Ant build scripts, so you’ll need an actual NetBeans installation to rebuild the project. Note that rebuilding will produce a bunch of unnecessary Java Web Start files, but I don’t see a way to disable that.

Myriarch Core

The source package contains the required Tektosyne library project and two Myriarch projects: the main project Myriarch for the JavaFX-based GUI executable, and the library project Myriarch.Core with the simulation algorithms and console runner. Myriarch.Core requires only the Compact 2 profile introduced in Java 8, so you could use it on platforms that don’t support JavaFX or other features requires by the main project.

Myriarch.Core contains an executable command-line runner intended for debugging and benchmarking the simulation code. Start the runner with java -jar Myriarch.Core.jar as usual. The built-in scenario Leuctra 371 BC will begin, with situation updates printed on each checkpoint. When finished the runner will save the simulation, then reload and replay the saved simulation. Edit Runner.java to change the executed actions.

The Javadoc class reference for the main project links into that for the core project, using relative file paths. For this to work you need to keep both projects side-by-side in the same parent directory. When rebuilding you must first generate Javadoc files for the core project, then for the main project.

6. Known Issues

See Known JavaFX Issues for potential serious compatibility problems.

Resizable windows do not have sensible minimum sizes because JavaFX does not currently scale minimum (or maximum) sizes with screen DPI. This bug will hopefully get fixed in a future Java release.

When saving simulations, the compressed format .xml.gz is preselected. Should you change to uncompressed XML, the new file ending .xml replaces only the .gz part of .xml.gz, resulting in the nonsenical double ending .xml.xml. This is an old bug in the native Windows file chooser dialog.

All files – individual files, multi-file packages, and individual files contained in multi-file packages – that constitute the original distribution of Myriarch are Copyright © 2012–2017 by Christoph Nahr, except where otherwise noted.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Exceptions

All user interface icons are rendered from the embedded Font Awesome by Dave Gandy, made available under the SIL Open Font License. This font is present as the separate file Myriarch/src/resources/FontAwesome.ttf in the source code package.

The application icon is taken from the replica of a decorated Corinthian helmet whose picture I found online somewhere in January 2012. Unfortunately I forgot to take note of the source and cannot find this exact model now, though there are plenty of similar helmets on offer.