Skip to content

Commit

Permalink
✨ Adds line segment feature for Aurora export
Browse files Browse the repository at this point in the history
  • Loading branch information
donatmarko committed Jan 14, 2020
1 parent b5b024a commit 02bded8
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 10 deletions.
15 changes: 14 additions & 1 deletion AIPcoord/frmMain.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 14 additions & 8 deletions AIPcoord/frmMain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -272,18 +272,24 @@ void CoordinateProcess(OutputType typ)
}
else if (typ == OutputType.Aurora)
{
if (rad_dms_14.Checked)
{
txt_aurora.AppendText(clist[i].ToString("AURORA_DMS14") + Environment.NewLine);
}
else if (rad_dms_11.Checked)
string format = "AURORA_DMS14";
if (rad_dms_11.Checked)
format = "AURORA_DMS11";
else if (rad_decimal.Checked)
format = "AURORA_DEC";

string s = string.Empty;
if (!chk_linesegments.Checked || clist.Count == 1)
{
txt_aurora.AppendText(clist[i].ToString("AURORA_DMS11") + Environment.NewLine);
// single point given or user wants point list
s = s + clist[i].ToString(format);
}
else if (rad_decimal.Checked)
else if (clist.Count > i + 1)
{
txt_aurora.AppendText(clist[i].ToString("AURORA_DEC") + Environment.NewLine);
// user wants line segment list
s = s + string.Format("{0}{1}", clist[i].ToString(format), clist[i + 1].ToString(format));
}
txt_aurora.AppendText(s + Environment.NewLine);
}
}

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ However the source coordinate format has to be eAIP-style WGS84 format, it **mig
Since 08/08/2018 the tool has been accepting IvAc 1 batch line segments as input too.

## Usage
Insert the source data and press one of the four buttons depending on the format you would like to get. Leading tabs can be adjusted for IVAC2, leading spaces and color attribute for IvAc1 format. For the Aurora, you can choose the 11- or 14-character-long DMS format or even the decimal format (similar to the WebEye one). The output will be moved to the clipboard, so you don't have to Ctrl-C the result manually. Basically that's all. :-)
Insert the source data and press one of the four buttons depending on the format you would like to get. Leading tabs can be adjusted for IVAC2, leading spaces and color attribute for IvAc1 format. For the Aurora, exporting the data into line segments and point list are both available, and in both cases you can choose between the 11- or 14-character-long DMS format or even the decimal format (similar to the WebEye one). The output will be moved to the clipboard, so you don't have to Ctrl-C the result manually. Basically that's all. :-)

Example input data which will surely work (eAIP format):
`474643N 0190652E - 473720N 0185425E - 473500N 0185300E - 473220N 0185858E - 473055N 0190118E - 473054N 0190159E - 473612N 0190412E - 474615N 0191631E - 474643N 0190652E`
Expand Down

0 comments on commit 02bded8

Please sign in to comment.