Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

More UI changes, including an icon

  • Loading branch information...
commit 40b360638e564d9e1f91a9b851719c401f1f0c92 1 parent 72da4f8
aeoth authored
View
1,024 markpad_logo.ai
1,024 additions, 0 deletions not shown
View
81 src/MarkPad/Document/DocumentView.xaml
@@ -1,37 +1,80 @@
-<UserControl
- x:Class="MarkPad.Document.DocumentView"
+<UserControl
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:shared="http://schemas.markpad.net/winfx/xaml/shared" xmlns:cal="http://www.caliburnproject.org"
- xmlns:awe="clr-namespace:Awesomium.Windows.Controls;assembly=Awesomium.Windows.Controls" mc:Ignorable="d"
+ xmlns:awe="clr-namespace:Awesomium.Windows.Controls;assembly=Awesomium.Windows.Controls" xmlns:avalonedit="http://icsharpcode.net/sharpdevelop/avalonedit"
+ x:Class="MarkPad.Document.DocumentView"
+ mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="300"
>
+ <UserControl.Resources>
+ <Style TargetType="{x:Type avalonedit:TextArea}">
+ <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
+ <Setter Property="SelectionBrush">
+ <Setter.Value>
+ <SolidColorBrush Color="{DynamicResource {x:Static SystemColors.HighlightColorKey}}" Opacity="0.7"/>
+ </Setter.Value>
+ </Setter>
+ <Setter Property="SelectionBorder">
+ <Setter.Value>
+ <Pen Brush="{DynamicResource {x:Static SystemColors.HighlightBrushKey}}" Thickness="1"/>
+ </Setter.Value>
+ </Setter>
+ <Setter Property="SelectionForeground" Value="{DynamicResource {x:Static SystemColors.HighlightTextBrushKey}}"/>
+ <Setter Property="Template">
+ <Setter.Value>
+ <ControlTemplate TargetType="{x:Type avalonedit:TextArea}">
+ <DockPanel Focusable="False">
+ <ItemsControl DockPanel.Dock="Left"
+ Focusable="False"
+ Margin="0,0,5,0"
+ FontSize="10"
+ FontFamily="Segoe UI"
+ Padding="10,0,0,0"
+ Background="#adDEDEDE"
+ ItemsSource="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=LeftMargins}">
+ <ItemsControl.ItemsPanel>
+ <ItemsPanelTemplate>
+ <StackPanel Orientation="Horizontal" />
+ </ItemsPanelTemplate>
+ </ItemsControl.ItemsPanel>
+ </ItemsControl>
+ <ContentPresenter
+ Panel.ZIndex="-1"
+ Focusable="False"
+ Content="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TextView}"/>
+ </DockPanel>
+ </ControlTemplate>
+ </Setter.Value>
+ </Setter>
+ </Style>
+ </UserControl.Resources>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
- <avalonEdit:TextEditor
- xmlns:avalonEdit="http://icsharpcode.net/sharpdevelop/avalonedit"
- Name="Document"
- WordWrap="True"
- Document="{Binding Document}"
- cal:Message.Attach="[Event TextChanged]=[Action Update]"
- Grid.Column="0"
- Margin="10"
- VerticalAlignment="Stretch"
- HorizontalAlignment="Stretch" Padding="10">
- <avalonEdit:TextEditor.Effect>
- <DropShadowEffect BlurRadius="5" Color="Black" ShadowDepth="0" Opacity="0.5" />
- </avalonEdit:TextEditor.Effect>
- </avalonEdit:TextEditor>
+ <avalonedit:TextEditor
+ x:Name="Document"
+ WordWrap="True"
+ ShowLineNumbers="True"
+ Document="{Binding Document}"
+ cal:Message.Attach="[Event TextChanged]=[Action Update]"
+ Grid.Column="0"
+ Margin="10,10,10,-5"
+ VerticalAlignment="Stretch"
+ HorizontalAlignment="Stretch" Padding="0,0,10,0">
+ <avalonedit:TextEditor.Effect>
+ <DropShadowEffect BlurRadius="10" Color="Black" Opacity="0.25" Direction="270" />
+ </avalonedit:TextEditor.Effect>
+ </avalonedit:TextEditor>
- <awe:WebControl Margin="10" Grid.Column="1" HorizontalAlignment="Stretch" shared:WebBrowserUtility.BindableContent="{Binding Render}">
+ <awe:WebControl Margin="10,10,10,-5" Grid.Column="1" HorizontalAlignment="Stretch" shared:WebBrowserUtility.BindableContent="{Binding Render}">
<awe:WebControl.Effect>
- <DropShadowEffect BlurRadius="5" Color="Black" ShadowDepth="0" Opacity="0.5" />
+ <DropShadowEffect BlurRadius="10" Color="Black" Opacity="0.25" Direction="270" />
</awe:WebControl.Effect>
</awe:WebControl>
</Grid>
View
2  src/MarkPad/Document/DocumentViewModel.cs
@@ -102,7 +102,7 @@ public bool HasChanges
public override string DisplayName
{
- get { return title + (HasChanges ? " *" : ""); }
+ get { return title; }
}
public override void CanClose(System.Action<bool> callback)
View
3  src/MarkPad/MDI/MDIView.xaml
@@ -8,6 +8,8 @@
d:DesignHeight="300" d:DesignWidth="300"
>
<UserControl.Resources>
+ <BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
+
<Style TargetType="TabItem">
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
<Setter Property="IsTabStop" Value="False" />
@@ -57,6 +59,7 @@
<DataTemplate>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding DisplayName}" />
+ <TextBlock Text="i" FontFamily="Marlett" Visibility="{Binding HasChanges, Converter={StaticResource BooleanToVisibilityConverter}}" />
<Button
Style="{DynamicResource ChromelessButtonStyle}"
Margin="5,0,15,0"
View
6 src/MarkPad/MarkPad.csproj
@@ -38,6 +38,9 @@
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
+ <PropertyGroup>
+ <ApplicationIcon>markpad.ico</ApplicationIcon>
+ </PropertyGroup>
<ItemGroup>
<Reference Include="Autofac">
<HintPath>..\..\packages\Autofac.2.5.2.830\lib\NET40\Autofac.dll</HintPath>
@@ -181,6 +184,9 @@
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
+ <ItemGroup>
+ <Resource Include="markpad.ico" />
+ </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
<!--<Import Project="$(SolutionDir)\tools\EmbedAssemblies.targets" />-->
View
38 src/MarkPad/Shell/ShellView.xaml
@@ -7,6 +7,7 @@
xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
xmlns:Behaviours="clr-namespace:MahApps.Metro.Behaviours;assembly=MahApps.Metro" mc:Ignorable="d"
MouseLeftButtonDown="DragMoveWindow"
+ Icon="../markpad.ico"
>
<i:Interaction.Behaviors>
<Behaviours:BorderlessWindowBehavior/>
@@ -18,11 +19,36 @@
<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Colours.xaml" />
<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
- <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/Blue.xaml" />
<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseLight.xaml" />
<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.AnimatedSingleRowTabControl.xaml" />
</ResourceDictionary.MergedDictionaries>
+ <!--ACCENT COLORS-->
+ <Color x:Key="HighlightDarkColor">#FFbe0606</Color>
+ <Color x:Key="HighlightLightColor">#FFbe0606</Color>
+
+ <Color x:Key="AccentDarkColor">#FFbe0606</Color>
+
+ <!--80%-->
+ <Color x:Key="AccentColor">#CCbe0606</Color>
+ <!--60%-->
+ <Color x:Key="AccentColor2">#99ff3333</Color>
+ <!--40%-->
+ <Color x:Key="AccentColor3">#66ff3333</Color>
+ <!--20%-->
+ <Color x:Key="AccentColor4">#33ff3333</Color>
+
+ <LinearGradientBrush x:Key="BrandingBrush"
+ EndPoint="0.001,0.5"
+ StartPoint="1.002,0.5">
+ <GradientStop Color="{DynamicResource HighlightDarkColor}"
+ Offset="0" />
+ <GradientStop Color="Blue"
+ Offset="1" />
+ </LinearGradientBrush>
+
+ <SolidColorBrush x:Key="AccentColorBrush"
+ Color="{DynamicResource AccentColor}" />
</ResourceDictionary>
</Window.Resources>
<Window.Background>
@@ -33,7 +59,8 @@
</Window.Background>
<DockPanel>
<Grid DockPanel.Dock="Top">
- <StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal" Margin="30,10,30,10">
+ <TextBlock TextWrapping="Wrap" VerticalAlignment="Top" d:LayoutOverrides="Width" FontWeight="Bold" FontSize="10.667" Margin="30,10,0,0"><Run Language="en-au" Text="MARKPAD"/></TextBlock>
+ <StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal" Margin="30,30,30,10">
<Button x:Name="NewDocument" Content="NEW" Style="{DynamicResource ChromelessButtonStyle}" FontSize="13.333" Margin="0,0,20,0" FontWeight="Bold" />
<Button x:Name="NewJekyllDocument" Content="NEW JEKYLL PAGE" Style="{DynamicResource ChromelessButtonStyle}" FontSize="13.333" Margin="0,0,20,0" FontWeight="Bold" />
<Button x:Name="OpenDocument" Content="OPEN" Style="{DynamicResource ChromelessButtonStyle}" FontSize="13.333" Margin="0,0,20,0" FontWeight="Bold" />
@@ -45,8 +72,13 @@
<Button Click="ButtonMaxRestoreOnClick" x:Name="maxRestore" Style="{DynamicResource ChromelessButtonStyle}" Content="1" FontFamily="Marlett" />
<Button x:Name="Exit" Style="{DynamicResource ChromelessButtonStyle}" Content="r" FontFamily="Marlett" />
</StackPanel>
+ <Rectangle HorizontalAlignment="Left" Stroke="Black" Width="10" StrokeThickness="0" Margin="0,10">
+ <Rectangle.Fill>
+ <SolidColorBrush Color="{DynamicResource HighlightDarkColor}" />
+ </Rectangle.Fill>
+ </Rectangle>
</Grid>
- <ContentControl x:Name="MDI" Margin="10,0,10,10" />
+ <ContentControl x:Name="MDI" Margin="10,0" />
</DockPanel>
</Window>
View
BIN  src/MarkPad/markpad.ico
Binary file not shown
Please sign in to comment.
Something went wrong with that request. Please try again.