Click here to Skip to main content
12,626,508 members (39,071 online)
Click here to Skip to main content

Stats

75.7K views
3.1K downloads
121 bookmarked
Posted

WPF Book Reader

, 10 May 2012 GPL3
A WPF book reader for cbz/cbr files
BookReader.exe.manifest
ICSharpCode.SharpZipLib.dll
SevenZipSharp.dll
WPFToolkit.dll
Dependencies
7z.dll
BookReader.application
BookReader.exe
BookReader
ClassDiagram.cd
Dependencies
7-zip.dll
7z.dll
ICSharpCode.SharpZipLib.dll
SevenZipSharp.dll
WPFToolkit.dll
Properties
app.manifest
Reader
Catalog
Common
Images
RAR
ZIP
Resources
TheRedPushPin.png
XAML
BookReader.application
BookReader.exe
BookReader.exe.manifest
7z.dll
SevenZipSharp.dll
WPFToolkit.dll
Release
BookReader.application
BookReader.exe
BookReader.exe.manifest
Dependencies
7z.dll
pdftohtml.exe
SevenZipSharp.dll
WPFToolkit.dll
BookReader.csproj.user
BookReader.csproj.vspscc
7z.dll
pdftohtml.exe
SevenZipSharp.dll
WPFToolkit.dll
app.manifest
acroread.png
document.png
ecran.png
exit.png
FitHeight.png
FitWidth.png
info.png
open_folder.png
refresh.png
Search.png
Theme
TheRedPushPin.png
tools.png
BookReader.csproj.user
ClassDiagram.cd
7-zip.dll
7z.dll
ICSharpCode.SharpZipLib.dll
SevenZipSharp.dll
WPFToolkit.dll
app.manifest
TheRedPushPin.png
BookReader.application
BookReader.exe
BookReader.exe.manifest
BookReader.vshost.exe
7z.dll
pdftohtml.exe
SevenZipSharp.dll
WPFToolkit.dll
BookReader.csproj.user
BookReader.csproj.vspscc
7z.dll
pdftohtml.exe
SevenZipSharp.dll
WPFToolkit.dll
app.manifest
acroread.png
book.ico
document.png
ecran.png
exit.png
FitHeight.png
FitWidth.png
info.png
open_folder.png
refresh.png
Search.png
TheRedPushPin.png
tools.png
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

    <LinearGradientBrush x:Key="windowBrush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Offset="0">
            <GradientStop.Color>
                <Color A="255" R="120" G="163" B="195"></Color>
            </GradientStop.Color>
        </GradientStop>
        <GradientStop Offset="0.5" >
            <GradientStop.Color>
                <Color A="255" R="214" G="222" B="235"></Color>
            </GradientStop.Color>
        </GradientStop>
        <GradientStop Offset="1">
            <GradientStop.Color>
                <Color A="255" R="120" G="163" B="195"></Color>
            </GradientStop.Color>
        </GradientStop>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="fillBrush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Offset="0" >
            <GradientStop.Color>
                <Color A="255" R="0" G="84" B="154"></Color>
            </GradientStop.Color>
        </GradientStop>
        <GradientStop Offset="1" >
            <GradientStop.Color>
                <Color A="255" R="2" G="24" B="84"></Color>
            </GradientStop.Color>
        </GradientStop>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="sliderBrush">
        <SolidColorBrush.Color>
            <Color A="255" R="217" G="227" B="239"/>
        </SolidColorBrush.Color>
    </SolidColorBrush>
    
    <!--minimize, maximize, close Buttons-->
    <Style x:Key="minimizeButton" TargetType="{x:Type Button}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">       
                    <Grid>
                        <Rectangle Stretch="Fill" Fill="Transparent"></Rectangle>
                        <Rectangle Name="content" HorizontalAlignment="Center" Stroke="Black" Width="10" Height="2" VerticalAlignment="Bottom" Fill="White" StrokeThickness="0" />
                    </Grid>    
                    <ControlTemplate.Triggers>
                        <Trigger Property="Button.IsMouseOver" Value="True">
                            <Setter TargetName="content" Property="Fill" Value="{StaticResource fillBrush}"/>
                        </Trigger>
                        <Trigger Property="Button.IsPressed" Value="True">
                            <Setter Property="RenderTransform" TargetName="content">
                                <Setter.Value>
                                    <TranslateTransform X="1" Y="1"/>
                                </Setter.Value>
                            </Setter>
                            <!--<Setter TargetName="buttonRect" Property="Fill" Value="Transparent"/>-->
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="maximizeButton" TargetType="{x:Type Button}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Grid>
                        <Rectangle Stretch="Fill" Fill="Transparent"></Rectangle>
                        <Rectangle HorizontalAlignment="Center" Name="content" Stroke="White" Width="9" Height="9" VerticalAlignment="Bottom" StrokeThickness="2" />
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="Button.IsMouseOver" Value="True">
                            <Setter TargetName="content" Property="Stroke" Value="{StaticResource fillBrush}"/>
                        </Trigger>
                        <Trigger Property="Button.IsPressed" Value="True">
                            <Setter Property="RenderTransform" TargetName="content">
                                <Setter.Value>
                                    <TranslateTransform X="1" Y="1"/>
                                </Setter.Value>
                            </Setter>
                            <!--<Setter TargetName="buttonRect" Property="Fill" Value="Transparent"/>-->
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    <Style x:Key="closeButton" TargetType="{x:Type Button}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Grid>
                        <Rectangle Stretch="Fill" Fill="Transparent"></Rectangle>
                        <Line Name="line1" X1="0" Y1="0" X2="8" Y2="8" Stroke="White" StrokeThickness="2" HorizontalAlignment="Center" VerticalAlignment="Bottom"></Line>
                        <Line Name="line2" X1="8" Y1="0" X2="0" Y2="8" Stroke="White" StrokeThickness="2" HorizontalAlignment="Center" VerticalAlignment="Bottom"></Line>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="Button.IsMouseOver" Value="True">
                            <Setter TargetName="line1" Property="Stroke" Value="{StaticResource fillBrush}"/>
                            <Setter TargetName="line2" Property="Stroke" Value="{StaticResource fillBrush}"/>
                        </Trigger>
                        <Trigger Property="Button.IsPressed" Value="True">
                            <Setter Property="RenderTransform" TargetName="line1">
                                <Setter.Value>
                                    <TranslateTransform X="1" Y="1"/>
                                </Setter.Value>
                            </Setter>
                            <Setter Property="RenderTransform" TargetName="line2">
                                <Setter.Value>
                                    <TranslateTransform X="1" Y="1"/>
                                </Setter.Value>
                            </Setter>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


</ResourceDictionary>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)

Share

About the Author

Guillaume Waser
Architect XEROX
France France
No Biography provided

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.161205.3 | Last Updated 10 May 2012
Article Copyright 2009 by Guillaume Waser
Everything else Copyright © CodeProject, 1999-2016
Layout: fixed | fluid