Skip to content

Commit

Permalink
Merge branch 'release/release_1.2.0'
Browse files Browse the repository at this point in the history
* release/release_1.2.0: (26 commits)
  Version change.
  Updated combined graph. Updated tooltips.
  Cleanup.
  Cleanup.
  Work in progress.
  Work in progress.
  Warning cleanup.
  Updated x-axis offsets.
  Updated OxyPlot
  Updates.
  Work in progress.
  Changed default URL. Removed old feed-reader. Added last date to graph text annotation.
  Updated OxyPlot.
  Text annotation changes.
  Graph related changes.
  Complete new approach: download all values from new site to a file (.csv) and read values from the file.
  Added change to text annotation.
  Change GUI font when renderer is changed.
  Change GUI font when renderer is changed.
  Added menu shortcuts.
  ...
  • Loading branch information
juusimaa committed Sep 10, 2014
2 parents ca642e0 + cfb5c2b commit afc3c51
Show file tree
Hide file tree
Showing 55 changed files with 3,164 additions and 39,831 deletions.
21 changes: 21 additions & 0 deletions EuriborSharp/CustonEventArgs/CustomEventArg.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System;
using EuriborSharp.Enums;

namespace EuriborSharp.CustonEventArgs
{
Expand All @@ -21,4 +22,24 @@ public BooleanEventArg(bool b)
value = b;
}
}

public class GraphStyleEventArgs : EventArgs
{
public readonly GraphStyle style;

public GraphStyleEventArgs(GraphStyle g)
{
style = g;
}
}

public class RendererEventArgs : EventArgs
{
public readonly Renderer value;

public RendererEventArgs(Renderer r)
{
value = r;
}
}
}
27 changes: 26 additions & 1 deletion EuriborSharp/Enums/Enums.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
namespace EuriborSharp.Enums
using System;

namespace EuriborSharp.Enums
{
/// <summary>
/// Available time periods.
/// </summary>
public enum TimePeriods
{
Default = 0,
Expand All @@ -10,4 +15,24 @@ public enum TimePeriods
SixMonths,
TwelveMonths
}

/// <summary>
/// Available serie styles.
/// </summary>
[Serializable]
public enum GraphStyle
{
Line,
Bar
}

/// <summary>
/// Available renderer for the graph.
/// </summary>
[Serializable]
public enum Renderer
{
Normal,
Xkcd
}
}
10 changes: 8 additions & 2 deletions EuriborSharp/EuriborSharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,14 @@
<ApplicationIcon>euro-1.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Reference Include="MoreLinq">
<HintPath>..\packages\morelinq.1.1.0\lib\net35\MoreLinq.dll</HintPath>
</Reference>
<Reference Include="OxyPlot">
<HintPath>..\packages\OxyPlot.WindowsForms.2014.1.318.1\lib\NET40\OxyPlot.dll</HintPath>
<HintPath>..\packages\OxyPlot.Core.2014.1.444\lib\portable-net4+sl4+wp71+win8\OxyPlot.dll</HintPath>
</Reference>
<Reference Include="OxyPlot.WindowsForms">
<HintPath>..\packages\OxyPlot.WindowsForms.2014.1.318.1\lib\NET40\OxyPlot.WindowsForms.dll</HintPath>
<HintPath>..\packages\OxyPlot.WindowsForms.2014.1.444\lib\net40\OxyPlot.WindowsForms.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand Down Expand Up @@ -138,6 +141,9 @@
<Content Include="euro-1.ico" />
<None Include="euro-1.png" />
</ItemGroup>
<ItemGroup>
<Folder Include="Resources\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
67 changes: 58 additions & 9 deletions EuriborSharp/EuriborSharpSettings.Designer.cs

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

18 changes: 15 additions & 3 deletions EuriborSharp/EuriborSharpSettings.settings
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,26 @@
<Setting Name="SmoothLine" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">True</Value>
</Setting>
<Setting Name="Xkcd" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">True</Value>
</Setting>
<Setting Name="DotLineSelected" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
<Setting Name="NormalLineSelected" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">True</Value>
</Setting>
<Setting Name="SelectedGraphStyle" Type="EuriborSharp.Enums.GraphStyle" Scope="User">
<Value Profile="(Default)">Line</Value>
</Setting>
<Setting Name="Autoload" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
<Setting Name="SelectedRenderer" Type="EuriborSharp.Enums.Renderer" Scope="User">
<Value Profile="(Default)">Xkcd</Value>
</Setting>
<Setting Name="XkcdSelected" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">True</Value>
</Setting>
<Setting Name="EuriborDefaultUrl" Type="System.String" Scope="User">
<Value Profile="(Default)">http://www.emmi-benchmarks.eu/assets/modules/rateisblue/processed_files/hist_EURIBOR_2014.csv</Value>
</Setting>
</Settings>
</SettingsFile>
1 change: 1 addition & 0 deletions EuriborSharp/Interfaces/IAboutFormPresenter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
interface IAboutFormPresenter
{
void ShowAboutForm();
void UpdateFonts(bool xkcdSelected);
}
}
26 changes: 21 additions & 5 deletions EuriborSharp/Interfaces/IGraphControl.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
namespace EuriborSharp.Interfaces
using EuriborSharp.Enums;

namespace EuriborSharp.Interfaces
{
interface IGraphControl
{
void Init(Enums.TimePeriods period, bool smoothSelected, bool xkcd);
/// <summary>
/// Initializies plot model and data series based on given parameters.
/// </summary>
/// <param name="period">Selected time period.</param>
/// <param name="smoothSelected">Flag for smooth line.</param>
/// <param name="style">Selected plot data serie type.</param>
/// <param name="renderer">Selected plot renderer.</param>
/// <param name="dotLine">Flag for dotted line.</param>
void Init(TimePeriods period, bool smoothSelected, GraphStyle style, Renderer renderer, bool dotLine);

/// <summary>
/// Updated selected plot data series.
/// </summary>
void UpdateGraph(TimePeriods period);

/// <summary>
/// Updated all plot data series.
/// </summary>
void UpdateGraph();
void UpdateSmoothing(bool b);
void SetLineStyleToNormal();
void SetLineStyleToDot();
}
}
2 changes: 2 additions & 0 deletions EuriborSharp/Interfaces/ILogControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ namespace EuriborSharp.Interfaces
{
public interface ILogControl
{
event EventHandler<BooleanEventArg> AutoloadChanged;
event EventHandler<StringEventArg> AddressChanged;
event EventHandler UpdateClicked;
event EventHandler ClearClicked;

void AddText(string s, bool append);
void UpdateAddress(string s);
void Init();
void SetupAutoload(bool enabled);
}
}
36 changes: 31 additions & 5 deletions EuriborSharp/Interfaces/IMainForm.cs
Original file line number Diff line number Diff line change
@@ -1,24 +1,50 @@
using System;
using System.Windows.Forms;
using EuriborSharp.CustonEventArgs;
using EuriborSharp.Enums;

namespace EuriborSharp.Interfaces
{
interface IMainForm
{
event EventHandler<BooleanEventArg> XkcdChanged;
/// <summary>
/// Occurs when smooth line enabled or disabled.
/// </summary>
event EventHandler<BooleanEventArg> LineSmoothChanged;
event EventHandler LineStyleNormalSelected;
event EventHandler LineStyleNoneSelected;

/// <summary>
/// Occurs when graph serie style is changed.
/// </summary>
event EventHandler<GraphStyleEventArgs> GraphStyleChanged;

/// <summary>
/// Occurs when renderer is changed.
/// </summary>
event EventHandler<RendererEventArgs> RendererChanged;

/// <summary>
/// Occurs when line style is changed.
/// </summary>
event EventHandler<BooleanEventArg> DotLineSelected;

/// <summary>
/// Occurs when about menu is selected from the menu.
/// </summary>
event EventHandler HelpSelected;

/// <summary>
/// Occurs when exit is selected from the menu.
/// </summary>
event EventHandler ExitSelected;

void Close();
void Dispose();
void AddControl(UserControl control, string tabName);
void UpdateTitle(string s);
void UpdateLineStyle(bool dotlineSelected);
void UpdateSmoothSelection(bool selected);
void UpdateLineStyleSelection(bool normalSelected);
void UpdateRendererSelection(bool xkcdSelected);
void UpdateSeriesStyle(GraphStyle g);
void UpdateRenderer(Renderer r);
void UpdateGui(bool xkcdSelected);
}
}
Loading

0 comments on commit afc3c51

Please sign in to comment.