diff --git a/coin.cabal b/coin.cabal
--- a/coin.cabal
+++ b/coin.cabal
@@ -1,5 +1,5 @@
 name:              coin
-version:           1.0
+version:           1.1
 Build-Type:        Simple
 cabal-version:     >= 1.16
 author:            Piotr Borek <piotrborek@op.pl>
@@ -9,32 +9,32 @@
 description:       Simple account manager
 category:          Application
 homepage:          https://bitbucket.org/borekpiotr/coin
+tested-with:       GHC == 7.10.3, GHC == 8.0.1
 
 data-files:        stack.yaml
                    LICENSE
-                   resources/i18n/pl/LC_MESSAGES/coin.mo
-                   resources/i18n/pl/LC_MESSAGES/coin.po
-                   resources/i18n/pl/LC_MESSAGES/convert
 
+flag debug-db
+    description: Output database logger information to stdout.
+    default: False
+
 executable coin
     main-is:            Main.hs
     hs-source-dirs:     src
     default-language:   Haskell2010
     -- also enable profiling in ~/.cabal.config
-    --ghc-options:        -Wall -prof -auto-all -osuf p_o
+    -- ghc-options:        -Wall -prof -auto-all -osuf p_o
     ghc-options:        -Wall -O2
     default-extensions: LambdaCase
                         PackageImports
                         MultiWayIf
-    build-depends:      base >= 4.8 && < 4.9,
+                        CPP
+    build-depends:      base >= 4.8 && < 5.0,
                         glib,
-                        gtk3 == 0.14.2,
+                        gtk3,
                         directory,
-                        setlocale,
-                        hgettext,
                         filepath,
                         containers,
-                        hgettext,
                         binary,
                         directory,
                         persistent,
@@ -47,9 +47,17 @@
                         resourcet,
                         time,
                         mtl,
-                        lens-simple,
+                        lens,
                         aeson,
                         bytestring
+    if flag(debug-db)
+        cpp-options:    -DDEBUG_DB
+    if os(windows)
+        build-depends:  Win32
+        cpp-options:    -DWINDOWS
+        if !flag(debug-db)
+            ghc-options: -optl-mwindows
+
     other-modules:      Coin.UI.Raports.RaportSummary
                         Coin.UI.Raports.RaportHistory
                         Coin.UI.Raports.RaportQuery
@@ -92,7 +100,9 @@
                         Coin.Utils.Exception
                         Coin.Utils.IORef
                         Coin.Utils.StringUtils
-                        Coin.Utils.I18N
                         Coin.Utils.PropertyMap
                         Coin.Utils.ColorUtils
-                        Coin.Utils.LocaleHelper
+                        Coin.Locale.LangPL
+                        Coin.Locale.LangUnknown
+                        Coin.Locale.Languages
+                        Coin.Locale.Translate
diff --git a/resources/i18n/pl/LC_MESSAGES/coin.mo b/resources/i18n/pl/LC_MESSAGES/coin.mo
deleted file mode 100644
Binary files a/resources/i18n/pl/LC_MESSAGES/coin.mo and /dev/null differ
diff --git a/resources/i18n/pl/LC_MESSAGES/coin.po b/resources/i18n/pl/LC_MESSAGES/coin.po
deleted file mode 100644
--- a/resources/i18n/pl/LC_MESSAGES/coin.po
+++ /dev/null
@@ -1,318 +0,0 @@
-# Translation file
-
-msgid ""
-msgstr ""
-
-"Project-Id-Version: PACKAGE VERSION\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-01-13 06:05-0800\n"
-"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
-"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
-"Language-Team: LANGUAGE <LL@li.org>\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "Date"
-msgstr "Data"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "From"
-msgstr "Z konta"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "To"
-msgstr "Na konto"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "Value"
-msgstr "Wartość"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "Tag"
-msgstr "Tag"
-
-#: src/Coin/UI/Accounts/OperationsView.hs:0
-msgid "Description"
-msgstr "Opis"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Date:"
-msgstr "Data:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Tag:"
-msgstr "Tag:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Add value:"
-msgstr "Dodaj wartość:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "To account:"
-msgstr "Na konto:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Description:"
-msgstr "Opis:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Current balance:"
-msgstr "Bieżące saldo:"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Add"
-msgstr "Dodaj"
-
-#: src/Coin/UI/Accounts/AccountsIncome.hs:0
-msgid "Remove"
-msgstr "Usuń"
-
-#: src/Coin/UI/Accounts/AccountsHistory.hs:0
-msgid "Account name:"
-msgstr "Nazwa konta:"
-
-#: src/Coin/UI/Accounts/AccountsOutcome.hs:0
-msgid "Subtract value:"
-msgstr "Odejmij wartość:"
-
-#: src/Coin/UI/Accounts/AccountsOutcome.hs:0
-msgid "From account:"
-msgstr "Z konta:"
-
-#: src/Coin/UI/Accounts/AccountsTransfer.hs:0
-msgid "Transfer value:"
-msgstr "Przelej wartość:"
-
-#: src/Coin/UI/Accounts/AccountsWidget.hs:0
-msgid "Income"
-msgstr "Wpłata"
-
-#: src/Coin/UI/Accounts/AccountsWidget.hs:0
-msgid "Outcome"
-msgstr "Wypłata"
-
-#: src/Coin/UI/Accounts/AccountsWidget.hs:0
-msgid "Transfer"
-msgstr "Przelew"
-
-#: src/Coin/UI/Accounts/AccountsWidget.hs:0
-msgid "History"
-msgstr "Historia"
-
-#: src/Coin/UI/Widgets/Calendar.hs:0
-msgid "Today"
-msgstr "Dziś"
-
-#: src/Coin/UI/Widgets/MessageBox.hs:0
-msgid "Info"
-msgstr "Informacja"
-
-#: src/Coin/UI/Widgets/MessageBox.hs:0
-msgid "Warning"
-msgstr "Ostrzeżenie"
-
-#: src/Coin/UI/Widgets/MessageBox.hs:0
-msgid "Question"
-msgstr "Pytanie"
-
-#: src/Coin/UI/Widgets/MessageBox.hs:0
-msgid "Error"
-msgstr "Błąd"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Mo"
-msgstr "Pn"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Tu"
-msgstr "Wt"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "We"
-msgstr "Śr"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Th"
-msgstr "Czw"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Fr"
-msgstr "Pt"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Sa"
-msgstr "So"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "Su"
-msgstr "N"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "January"
-msgstr "Styczeń"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "February"
-msgstr "Luty"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "March"
-msgstr "Marzec"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "April"
-msgstr "Kwiecień"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "May"
-msgstr "Maj"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "June"
-msgstr "Czerwiec"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "July"
-msgstr "Lipiec"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "August"
-msgstr "Sierpień"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "September"
-msgstr "Wrzesień"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "October"
-msgstr "Październik"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "November"
-msgstr "Listopad"
-
-#: src/Coin/UI/Utils/CalendarUtils.hs:0
-msgid "December"
-msgstr "Grudzień"
-
-#: src/Coin/UI/MainMultiList.hs:0
-msgid "Accounts"
-msgstr "Konta"
-
-#: src/Coin/UI/MainMultiList.hs:0
-msgid "Raports"
-msgstr "Raporty"
-
-#: src/Coin/UI/MainMultiList.hs:0
-msgid "Options"
-msgstr "Opcje"
-
-#: src/Coin/UI/MainMultiList.hs:0
-msgid "Tags"
-msgstr "Tagi"
-
-#: src/Coin/DB/Tables.hs:0
-msgid "None"
-msgstr "Żaden"
-
-#: src/Coin/DB/Tables.hs:0
-msgid "Cash"
-msgstr "Gotówka"
-
-msgid "Do you want to update"
-msgstr "Czy chcesz zmienić nazwę"
-
-msgid "Do you want to remove"
-msgstr "Czy chcesz usunąć"
-
-msgid "account ?"
-msgstr " "
-
-msgid "account name ?"
-msgstr " "
-
-msgid "tag ?"
-msgstr " "
-
-msgid "tag name ?"
-msgstr " "
-
-msgid "Name"
-msgstr "Nazwa"
-
-msgid "Incomes:"
-msgstr "Wpłaty:"
-
-msgid "Outcomes:"
-msgstr "Wypłaty:"
-
-msgid "Account name"
-msgstr "Nazwa konta"
-
-msgid "Current balance"
-msgstr "Bieżące saldo"
-
-msgid "Sum"
-msgstr "Suma"
-
-msgid "Summary"
-msgstr "Podsumowanie"
-
-msgid "Queries"
-msgstr "Zapytania"
-
-msgid "All"
-msgstr "Wszystkie"
-
-msgid "Period of time"
-msgstr "Okres czasu"
-
-msgid "last 1 month"
-msgstr "ostatni 1 miesiąc"
-
-msgid "last 2 months"
-msgstr "ostatnie 2 miesiące"
-
-msgid "last 3 months"
-msgstr "ostatnie 3 miesiące"
-
-msgid "last 6 months"
-msgstr "ostatnie 6 miesięcy"
-
-msgid "last 1 year"
-msgstr "ostatni 1 rok"
-
-msgid "last 2 years"
-msgstr "ostatnie 2 lata"
-
-msgid "last 3 years"
-msgstr "ostatnie 3 lata"
-
-msgid "last 5 years"
-msgstr "ostatnie 5 lat"
-
-msgid "last 10 years"
-msgstr "ostatnie 10 lat"
-
-msgid "Time from"
-msgstr "Czas od"
-
-msgid "Time to"
-msgstr "Czas do"
-
-msgid "Time from ... to ..."
-msgstr "Czas od ... do ..."
-
-msgid "Last month/year"
-msgstr "Ostatni miesiąc/rok"
-
-msgid "Actions"
-msgstr "Operacje"
-
-msgid "Select all"
-msgstr "Zaznacz wszystkie"
-
-msgid "Deselect all"
-msgstr "Odznacz wszystkie"
diff --git a/resources/i18n/pl/LC_MESSAGES/convert b/resources/i18n/pl/LC_MESSAGES/convert
deleted file mode 100644
--- a/resources/i18n/pl/LC_MESSAGES/convert
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/bash
-
-msgfmt coin.po -o coin.mo
diff --git a/src/Coin/Config/Dirs.hs b/src/Coin/Config/Dirs.hs
--- a/src/Coin/Config/Dirs.hs
+++ b/src/Coin/Config/Dirs.hs
@@ -24,10 +24,10 @@
     configGetDirectory
 ) where
 
-import System.Environment
+import System.Directory
 import System.FilePath
 
 configGetDirectory :: IO String
 configGetDirectory = do
-    home <- getEnv "HOME"
+    home <- getHomeDirectory
     return $ home </> ".coin"
diff --git a/src/Coin/DB/Functions.hs b/src/Coin/DB/Functions.hs
--- a/src/Coin/DB/Functions.hs
+++ b/src/Coin/DB/Functions.hs
@@ -48,10 +48,17 @@
 
 type EntityCache = Map.Map T.Text JSON.Value
 
+#ifdef DEBUG_DB
 runDB :: (MonadBaseControl IO m, MonadIO m) => SqlPersistT (LoggingT (ResourceT (State.StateT EntityCache m))) a -> m a
 runDB action = do
     dir <- liftIO configGetDirectory
     State.evalStateT (runResourceT $ runStdoutLoggingT $ withSqliteConn (T.pack $ dir ++ "/coin.db") . runSqlConn $ action) Map.empty
+#else
+runDB :: (MonadBaseControl IO m, MonadIO m) => SqlPersistT (NoLoggingT (ResourceT (State.StateT EntityCache m))) a -> m a
+runDB action = do
+    dir <- liftIO configGetDirectory
+    State.evalStateT (runResourceT $ runNoLoggingT $ withSqliteConn (T.pack $ dir ++ "/coin.db") . runSqlConn $ action) Map.empty
+#endif
 
 rawSqlFirstCached :: (MonadLogger m, MonadIO m, State.MonadState EntityCache m, JSON.ToJSON a, JSON.FromJSON a, RawSql a) => String -> ReaderT SqlBackend m (Maybe a)
 rawSqlFirstCached stmt = listToMaybe <$> rawSqlCached stmt
diff --git a/src/Coin/DB/Tables.hs b/src/Coin/DB/Tables.hs
--- a/src/Coin/DB/Tables.hs
+++ b/src/Coin/DB/Tables.hs
@@ -46,7 +46,7 @@
 import Database.Persist.TH
 
 import Coin.DB.Functions
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Config.Dirs
 
 share [mkPersist sqlSettings, mkMigrate "migrateAll"] [persistUpperCase|
@@ -140,9 +140,11 @@
 initializeDatabase = do
     dir <- configGetDirectory
     createDirectoryIfMissing True dir
-
+#ifdef DEBUG_DB
     runDB $ runMigration migrateAll
-
+#else
+    void $ runDB $ runMigrationSilent migrateAll
+#endif
     void tagsTableNoneID
     void accountsTableIncomeID
     void accountsTableOutcomeID
diff --git a/src/Coin/Locale/LangPL.hs b/src/Coin/Locale/LangPL.hs
new file mode 100644
--- /dev/null
+++ b/src/Coin/Locale/LangPL.hs
@@ -0,0 +1,101 @@
+{-
+ *  Programmer:	Piotr Borek
+ *  E-mail:     piotrborek@op.pl
+ *  Copyright 2016 Piotr Borek
+ *
+ *  Distributed under the terms of the GPL (GNU Public License)
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+-}
+
+module Coin.Locale.LangPL where
+
+translate :: String -> String
+translate "Date"                  = "Data"
+translate "From"                  = "Z konta"
+translate "To"                    = "Na konto"
+translate "Value"                 = "Wartość"
+translate "Tag"                   = "Tag"
+translate "Description"           = "Opis"
+translate "Date:"                 = "Data:"
+translate "Tag:"                  = "Tag:"
+translate "Add value:"            = "Dodaj wartość:"
+translate "To account:"           = "Na konto:"
+translate "Description:"          = "Opis:"
+translate "Current balance:"      = "Bieżące saldo:"
+translate "Add"                   = "Dodaj"
+translate "Remove"                = "Usuń"
+translate "Account name:"         = "Nazwa konta:"
+translate "Subtract value:"       = "Odejmij wartość:"
+translate "From account:"         = "Z konta:"
+translate "Transfer value:"       = "Przelej wartość:"
+translate "Income"                = "Wpłata"
+translate "Outcome"               = "Wypłata"
+translate "Transfer"              = "Przelew"
+translate "History"               = "Historia"
+translate "Today"                 = "Dziś"
+translate "Info"                  = "Informacja"
+translate "Warning"               = "Ostrzeżenie"
+translate "Question"              = "Pytanie"
+translate "Error"                 = "Błąd"
+translate "Mo"                    = "Pn"
+translate "Tu"                    = "Wt"
+translate "We"                    = "Śr"
+translate "Th"                    = "Czw"
+translate "Fr"                    = "Pt"
+translate "Sa"                    = "So"
+translate "Su"                    = "N"
+translate "January"               = "Styczeń"
+translate "February"              = "Luty"
+translate "March"                 = "Marzec"
+translate "April"                 = "Kwiecień"
+translate "May"                   = "Maj"
+translate "June"                  = "Czerwiec"
+translate "July"                  = "Lipiec"
+translate "August"                = "Sierpień"
+translate "September"             = "Wrzesień"
+translate "October"               = "Październik"
+translate "November"              = "Listopad"
+translate "December"              = "Grudzień"
+translate "Accounts"              = "Konta"
+translate "Raports"               = "Raporty"
+translate "Options"               = "Opcje"
+translate "Tags"                  = "Tagi"
+translate "None"                  = "Żaden"
+translate "Cash"                  = "Gotówka"
+translate "Do you want to update" = "Czy chcesz zmienić nazwę"
+translate "Do you want to remove" = "Czy chcesz usunąć"
+translate "account ?"             = " "
+translate "account name ?"        = " "
+translate "tag ?"                 = " "
+translate "tag name ?"            = " "
+translate "Name"                  = "Nazwa"
+translate "Incomes:"              = "Wpłaty:"
+translate "Outcomes:"             = "Wypłaty:"
+translate "Account name"          = "Nazwa konta"
+translate "Current balance"       = "Bieżące saldo"
+translate "Sum"                   = "Suma"
+translate "Summary"               = "Podsumowanie"
+translate "Queries"               = "Zapytania"
+translate "All"                   = "Wszystkie"
+translate "Period of time"        = "Okres czasu"
+translate "Time from"             = "Czas od"
+translate "Time to"               = "Czas do"
+translate "Time from ... to ..."  = "Czas od ... do ..."
+translate "Last month/year"       = "Ostatni miesiąc/rok"
+translate "Actions"               = "Operacje"
+translate "Select all"            = "Zaznacz wszystkie"
+translate "Deselect all"          = "Odznacz wszystkie"
+translate x                       = x
diff --git a/src/Coin/Locale/LangUnknown.hs b/src/Coin/Locale/LangUnknown.hs
new file mode 100644
--- /dev/null
+++ b/src/Coin/Locale/LangUnknown.hs
@@ -0,0 +1,26 @@
+{-
+ *  Programmer:	Piotr Borek
+ *  E-mail:     piotrborek@op.pl
+ *  Copyright 2016 Piotr Borek
+ *
+ *  Distributed under the terms of the GPL (GNU Public License)
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+-}
+
+module Coin.Locale.LangUnknown where
+
+translate :: String -> String
+translate = id
diff --git a/src/Coin/Locale/Languages.hs b/src/Coin/Locale/Languages.hs
new file mode 100644
--- /dev/null
+++ b/src/Coin/Locale/Languages.hs
@@ -0,0 +1,58 @@
+{-
+ *  Programmer:	Piotr Borek
+ *  E-mail:     piotrborek@op.pl
+ *  Copyright 2016 Piotr Borek
+ *
+ *  Distributed under the terms of the GPL (GNU Public License)
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+-}
+
+module Coin.Locale.Languages (
+    LANG (..),
+    getSystemLanguage
+) where
+
+#ifdef WINDOWS
+import System.Win32.NLS
+#else
+import System.Environment
+#endif
+
+import System.IO.Unsafe
+
+data LANG = LANG_UNKNOWN
+          | LANG_PL
+          deriving Show
+
+#ifdef WINDOWS
+detectLanguage :: IO LANG
+detectLanguage = do
+    let lang = getUserDefaultLCID
+    case lang of
+        1045 -> return LANG_PL
+        _    -> return LANG_UNKNOWN
+#else
+detectLanguage :: IO LANG
+detectLanguage = do
+    lang <- getEnv "LANG"
+    case lang of
+        'p':'l':'_':'P':'L':_ -> return LANG_PL
+        _                     -> return LANG_UNKNOWN
+#endif
+
+{-# NOINLINE getSystemLanguage #-}
+getSystemLanguage :: LANG
+getSystemLanguage = unsafePerformIO detectLanguage
diff --git a/src/Coin/Locale/Translate.hs b/src/Coin/Locale/Translate.hs
new file mode 100644
--- /dev/null
+++ b/src/Coin/Locale/Translate.hs
@@ -0,0 +1,39 @@
+{-
+ *  Programmer:	Piotr Borek
+ *  E-mail:     piotrborek@op.pl
+ *  Copyright 2016 Piotr Borek
+ *
+ *  Distributed under the terms of the GPL (GNU Public License)
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+-}
+
+module Coin.Locale.Translate (
+    translate,
+    __
+) where
+
+import qualified Coin.Locale.LangPL as PL
+import qualified Coin.Locale.LangUnknown as UNKNOWN
+
+import Coin.Locale.Languages
+
+translate :: String -> String
+translate = case getSystemLanguage of
+    LANG_PL      -> PL.translate
+    LANG_UNKNOWN -> UNKNOWN.translate
+
+__ :: String -> String
+__ = translate
diff --git a/src/Coin/UI/Accounts/AccountsHistory.hs b/src/Coin/UI/Accounts/AccountsHistory.hs
--- a/src/Coin/UI/Accounts/AccountsHistory.hs
+++ b/src/Coin/UI/Accounts/AccountsHistory.hs
@@ -32,7 +32,7 @@
 
 import Coin.DB.Tables
 import Coin.DB.Functions
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.UI.MainState
 import Coin.UI.Builder.GtkUIBuilder
diff --git a/src/Coin/UI/Accounts/AccountsIncome.hs b/src/Coin/UI/Accounts/AccountsIncome.hs
--- a/src/Coin/UI/Accounts/AccountsIncome.hs
+++ b/src/Coin/UI/Accounts/AccountsIncome.hs
@@ -42,7 +42,7 @@
 import Coin.UI.Builder.GtkUIBuilder
 import Coin.UI.TagsComboBox
 import Coin.UI.Utils.CalendarUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.UI.HistoryView
 
diff --git a/src/Coin/UI/Accounts/AccountsOutcome.hs b/src/Coin/UI/Accounts/AccountsOutcome.hs
--- a/src/Coin/UI/Accounts/AccountsOutcome.hs
+++ b/src/Coin/UI/Accounts/AccountsOutcome.hs
@@ -42,7 +42,7 @@
 import Coin.UI.Builder.GtkUIBuilder
 import Coin.UI.TagsComboBox
 import Coin.UI.Utils.CalendarUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.UI.HistoryView
 
diff --git a/src/Coin/UI/Accounts/AccountsTransfer.hs b/src/Coin/UI/Accounts/AccountsTransfer.hs
--- a/src/Coin/UI/Accounts/AccountsTransfer.hs
+++ b/src/Coin/UI/Accounts/AccountsTransfer.hs
@@ -43,7 +43,7 @@
 import Coin.UI.TagsComboBox
 import Coin.UI.AccountsComboBox
 import Coin.UI.Utils.CalendarUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.UI.HistoryView
 
diff --git a/src/Coin/UI/Accounts/AccountsWidget.hs b/src/Coin/UI/Accounts/AccountsWidget.hs
--- a/src/Coin/UI/Accounts/AccountsWidget.hs
+++ b/src/Coin/UI/Accounts/AccountsWidget.hs
@@ -32,7 +32,7 @@
 
 import Coin.UI.MainState
 import Coin.UI.Builder.GtkUIBuilder
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.UI.Accounts.AccountsIncome
 import Coin.UI.Accounts.AccountsOutcome
 import Coin.UI.Accounts.AccountsTransfer
diff --git a/src/Coin/UI/Builder/GtkUIBuilder.hs b/src/Coin/UI/Builder/GtkUIBuilder.hs
--- a/src/Coin/UI/Builder/GtkUIBuilder.hs
+++ b/src/Coin/UI/Builder/GtkUIBuilder.hs
@@ -79,7 +79,7 @@
 import Control.Monad.IO.Class
 import Control.Monad.State.Strict
 import Data.Maybe
-import Lens.Simple
+import Control.Lens
 
 import Coin.UI.Builder.GtkUIAttributes
 import Coin.UI.Builder.GtkUIBuilderState
diff --git a/src/Coin/UI/Builder/GtkUIBuilderState.hs b/src/Coin/UI/Builder/GtkUIBuilderState.hs
--- a/src/Coin/UI/Builder/GtkUIBuilderState.hs
+++ b/src/Coin/UI/Builder/GtkUIBuilderState.hs
@@ -30,7 +30,7 @@
 import qualified Graphics.UI.Gtk as Gtk
 
 import Control.Monad.State.Strict
-import Lens.Simple
+import Control.Lens
 
 import Coin.UI.Builder.GtkUIAttributes
 
diff --git a/src/Coin/UI/Builder/GtkUIUtils.hs b/src/Coin/UI/Builder/GtkUIUtils.hs
--- a/src/Coin/UI/Builder/GtkUIUtils.hs
+++ b/src/Coin/UI/Builder/GtkUIUtils.hs
@@ -35,7 +35,7 @@
 import Control.Monad
 import Control.Monad.State.Strict
 import Data.Maybe
-import Lens.Simple
+import Control.Lens
 
 import Coin.UI.Utils.CssUtils
 import Coin.UI.Builder.GtkUIBuilderState
diff --git a/src/Coin/UI/HistoryView.hs b/src/Coin/UI/HistoryView.hs
--- a/src/Coin/UI/HistoryView.hs
+++ b/src/Coin/UI/HistoryView.hs
@@ -40,7 +40,7 @@
 import Coin.DB.Functions
 import Coin.UI.MainState
 import Coin.UI.Utils.CalendarUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.Utils.TableView
 
diff --git a/src/Coin/UI/MainMultiList.hs b/src/Coin/UI/MainMultiList.hs
--- a/src/Coin/UI/MainMultiList.hs
+++ b/src/Coin/UI/MainMultiList.hs
@@ -30,7 +30,7 @@
 import Database.Persist
 
 import Coin.DB.Tables
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.UI.MainState
 import Coin.UI.Widgets.StackWidget
 import Coin.UI.Widgets.MultiList
@@ -55,7 +55,7 @@
     multiListOptionAdd' multiList raportsIndex
         [ (__"Summary",
                do
-                   stackWidgetGet stack "raportSummary" >>= raportSummaryUpdate' mainState
+                   stackWidgetGet stack "raportSummary" >>= raportSummaryUpdate'
                    stackWidgetShow stack "raportSummary")
         , (__"History",
                do
diff --git a/src/Coin/UI/MainWindow.hs b/src/Coin/UI/MainWindow.hs
--- a/src/Coin/UI/MainWindow.hs
+++ b/src/Coin/UI/MainWindow.hs
@@ -64,7 +64,8 @@
     stackWidgetAdd stack "raportSummary" raportSummary
     stackWidgetAdd stack "raportQuery" raportQuery
 
-    (getObject, root) <- uiBuildGtk $
+    (getObject, root) <- uiBuildGtk $ do
+        windowAttrs [ windowTitle := "Coin"]
         window Nothing "" $
             scrolledWindow Nothing $
                 hPaned (Just "paned")
@@ -109,7 +110,7 @@
         stackIndex <- liftIO $ stackWidgetGetVisible stack
         propertyInsertMaybe "stackIndex" stackIndex
 
-    windowResize mainWindow 800 600
+    windowResize mainWindow 1024 768
     panedSetPosition paned 200
 
     mainStateReadPropertiesAction mainState "Coin.UI.MainWindow" $ do
diff --git a/src/Coin/UI/Options/OptionsAccount.hs b/src/Coin/UI/Options/OptionsAccount.hs
--- a/src/Coin/UI/Options/OptionsAccount.hs
+++ b/src/Coin/UI/Options/OptionsAccount.hs
@@ -37,7 +37,7 @@
 
 import Coin.DB.Tables
 import Coin.DB.Functions
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.StringUtils
 import Coin.UI.Widgets.MessageBox
 import Coin.Utils.TableView
diff --git a/src/Coin/UI/Options/OptionsTag.hs b/src/Coin/UI/Options/OptionsTag.hs
--- a/src/Coin/UI/Options/OptionsTag.hs
+++ b/src/Coin/UI/Options/OptionsTag.hs
@@ -36,7 +36,7 @@
 
 import Coin.DB.Tables
 import Coin.DB.Functions
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.StringUtils
 import Coin.UI.Widgets.MessageBox
 import Coin.Utils.TableView
diff --git a/src/Coin/UI/Raports/RaportHistory.hs b/src/Coin/UI/Raports/RaportHistory.hs
--- a/src/Coin/UI/Raports/RaportHistory.hs
+++ b/src/Coin/UI/Raports/RaportHistory.hs
@@ -42,7 +42,7 @@
 
 import Coin.DB.Tables
 import Coin.DB.Functions
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 import Coin.UI.MainState
 import Coin.UI.Builder.GtkUIBuilder
diff --git a/src/Coin/UI/Raports/RaportQuery.hs b/src/Coin/UI/Raports/RaportQuery.hs
--- a/src/Coin/UI/Raports/RaportQuery.hs
+++ b/src/Coin/UI/Raports/RaportQuery.hs
@@ -47,7 +47,7 @@
 import Coin.UI.Widgets.Calendar
 import Coin.UI.HistoryView
 import Coin.UI.Utils.CalendarUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.ValueParser
 
 data RaportQueryWidget = RaportQueryWidget {
@@ -159,6 +159,9 @@
                           root
                           fromCalendar
                           toCalendar
+
+    Gtk.toggleButtonSetActive incomeCheckButton True
+    Gtk.toggleButtonSetActive outcomeCheckButton True
 
     observableRegister (mainStateAccountsUpdated mainState) $ \entities -> do
         checkListClear accountsList
diff --git a/src/Coin/UI/Raports/RaportSummary.hs b/src/Coin/UI/Raports/RaportSummary.hs
--- a/src/Coin/UI/Raports/RaportSummary.hs
+++ b/src/Coin/UI/Raports/RaportSummary.hs
@@ -35,20 +35,22 @@
 import Control.Monad
 import Data.Foldable
 import Data.Int
+import Data.IORef
 import Database.Persist
 
 import Coin.DB.Tables
 import Coin.DB.Functions
 import Coin.UI.MainState
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.Utils.TableView
 import Coin.Utils.ValueParser
 
 type SummaryData = (String, String)
 
 data RaportSummaryWidget = RaportSummaryWidget {
-    raportSummaryRoot  :: Gtk.TreeView,
-    raportSummaryStore :: Gtk.ListStore SummaryData
+    raportSummaryRoot     :: Gtk.TreeView,
+    raportSummaryStore    :: Gtk.ListStore SummaryData,
+    raportSummaryAccounts :: IORef [Entity AccountsTable]
 }
 
 instance Gtk.GObjectClass RaportSummaryWidget where
@@ -74,21 +76,24 @@
     forM_ [col1, col2] $ Gtk.treeViewAppendColumn treeView
     Gtk.treeViewSetHeadersVisible treeView True
 
-    let raportSummary = RaportSummaryWidget treeView store
-    raportSummaryUpdate mainState raportSummary
+    accounts <- newIORef []
+    let raportSummary = RaportSummaryWidget treeView store accounts
+    raportSummaryUpdate raportSummary
 
     q <- Gtk.quarkFromString "Coin.UI.Raports.RaportSummary"
     Gtk.objectSetAttribute q treeView $ Just raportSummary
 
+    observableRegister (mainStateAccountsUpdated mainState) $ \entities -> modifyIORef' accounts (const entities)
+
     return raportSummary
 
-raportSummaryUpdate' :: Gtk.WidgetClass cls => MainState -> cls -> IO ()
-raportSummaryUpdate' mainState widget = castToRaportSummary widget >>= raportSummaryUpdate mainState
+raportSummaryUpdate' :: Gtk.WidgetClass cls => cls -> IO ()
+raportSummaryUpdate' widget = castToRaportSummary widget >>= raportSummaryUpdate
 
-raportSummaryUpdate :: MainState -> RaportSummaryWidget -> IO ()
-raportSummaryUpdate mainState raportSummary = do
+raportSummaryUpdate :: RaportSummaryWidget -> IO ()
+raportSummaryUpdate raportSummary = do
     let store = raportSummaryStore raportSummary
-    (list, s) <- raportSummarySelect mainState
+    (list, s) <- raportSummarySelect raportSummary
 
     Gtk.listStoreClear store
     forM_ list $ Gtk.listStoreAppend store
@@ -96,17 +101,18 @@
     void $ Gtk.listStoreAppend store ("--------", "")
     void $ Gtk.listStoreAppend store (__"Sum", valueShow s)
 
-raportSummarySelect :: MainState -> IO ([SummaryData], Int64)
-raportSummarySelect mainState = do
-    let incomeID = mainStateIncomeID mainState
-    let outcomeID = mainStateOutcomeID mainState
+raportSummarySelect :: RaportSummaryWidget -> IO ([SummaryData], Int64)
+raportSummarySelect raportSummary = do
+    entities <- readIORef $ raportSummaryAccounts raportSummary
 
-    entities <- runDB $
-        selectList [ AccountsTableId !=. incomeID, AccountsTableId !=. outcomeID] []
+    entities' <- forM entities $ \(Entity accountID _) ->
+        runDB $ do
+            (Just e) <- selectFirst [AccountsTableId ==. accountID] []
+            return e
 
-    let s = foldr' (\(Entity _ account) x -> x + accountsTableBalance account ) 0 entities
+    let s = foldr' (\(Entity _ account) x -> x + accountsTableBalance account ) 0 entities'
 
-    let list = flip map entities $ \(Entity _ account) ->
+    let list = flip map entities' $ \(Entity _ account) ->
                    (accountsTableName account, valueShow $ accountsTableBalance account)
 
     return (list, s)
diff --git a/src/Coin/UI/Utils/CalendarUtils.hs b/src/Coin/UI/Utils/CalendarUtils.hs
--- a/src/Coin/UI/Utils/CalendarUtils.hs
+++ b/src/Coin/UI/Utils/CalendarUtils.hs
@@ -38,7 +38,7 @@
 import Data.Time
 import Data.Time.Calendar.WeekDate
 
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 
 data Days = Monday
           | Tuesday
diff --git a/src/Coin/UI/Widgets/Calendar.hs b/src/Coin/UI/Widgets/Calendar.hs
--- a/src/Coin/UI/Widgets/Calendar.hs
+++ b/src/Coin/UI/Widgets/Calendar.hs
@@ -42,7 +42,7 @@
 import Coin.UI.Utils.CalendarUtils
 import Coin.UI.Utils.CssUtils
 import Coin.UI.Utils.Observable
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 
 data CalendarWidget = CalendarWidget {
     calendarContainer     :: Gtk.Box,
@@ -122,7 +122,11 @@
               , "#Arrow {"
               , "    font-weight: bold;"
               , if calendarSize == CalendarSizeNormal then "    font-size: 2em;" else mempty
+#ifdef WINDOWS
+              , "    padding: 0px 4px 6px 4px;"
+#else
               , "    padding: 0px;"
+#endif
               , "    border-style: none;"
               , "    border-radius: 12px;"
               , "}"
diff --git a/src/Coin/UI/Widgets/CheckList.hs b/src/Coin/UI/Widgets/CheckList.hs
--- a/src/Coin/UI/Widgets/CheckList.hs
+++ b/src/Coin/UI/Widgets/CheckList.hs
@@ -40,7 +40,7 @@
 import Data.Foldable
 import Data.IORef
 
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.UI.Builder.GtkUIBuilder
 
 data CheckListWidget a = CheckListWidget {
diff --git a/src/Coin/UI/Widgets/MessageBox.hs b/src/Coin/UI/Widgets/MessageBox.hs
--- a/src/Coin/UI/Widgets/MessageBox.hs
+++ b/src/Coin/UI/Widgets/MessageBox.hs
@@ -28,7 +28,7 @@
 import Graphics.UI.Gtk
 
 import Coin.UI.Builder.GtkUIBuilder
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 import Coin.UI.Widgets.ResponseButtons
 import Coin.UI.Utils.CssUtils
 
diff --git a/src/Coin/UI/Widgets/MiniCalendar.hs b/src/Coin/UI/Widgets/MiniCalendar.hs
--- a/src/Coin/UI/Widgets/MiniCalendar.hs
+++ b/src/Coin/UI/Widgets/MiniCalendar.hs
@@ -41,7 +41,7 @@
 import Coin.UI.Utils.CalendarUtils
 import Coin.UI.Utils.Observable
 import Coin.Utils.ColorUtils
-import Coin.Utils.I18N
+import Coin.Locale.Translate
 
 data MiniCalendarWidget = MiniCalendarWidget {
     miniCalendarContainer  :: Gtk.Box,
@@ -100,7 +100,7 @@
               , "    transition: none;"
               , "    font-size: 1em;"
               , "    border-radius: 8px 0px 8px 0px;"
-              , "    padding: 0px;"
+              , "    padding: 0px 12px 0px 12px;"
               , "}"
               , "#TodayButton:active {"
               , "    background-color: " ++ sb ++ ";"
@@ -108,7 +108,11 @@
               , "#Arrow {"
               , "    font-weight: bold;"
               , "    font-size: 2em;"
+#ifdef WINDOWS
+              , "    padding: 0px 6px 6px 6px;"
+#else
               , "    padding: 0px 6px 0px 6px;"
+#endif
               , "    border-style: none;"
               , "    border-radius: 12px;"
               , "}"
diff --git a/src/Coin/Utils/I18N.hs b/src/Coin/Utils/I18N.hs
deleted file mode 100644
--- a/src/Coin/Utils/I18N.hs
+++ /dev/null
@@ -1,30 +0,0 @@
-{-  
- *  Programmer:	Piotr Borek
- *  E-mail:     piotrborek@op.pl
- *  Copyright 2014 Piotr Borek
- *
- *  Distributed under the terms of the GPL (GNU Public License)
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
--}
-
-module Coin.Utils.I18N where
-
-import Text.I18N.GetText
-import System.IO.Unsafe
-
-{-# NOINLINE __ #-}
-__ :: String -> String
-__ = unsafePerformIO . getText
diff --git a/src/Coin/Utils/LocaleHelper.hs b/src/Coin/Utils/LocaleHelper.hs
deleted file mode 100644
--- a/src/Coin/Utils/LocaleHelper.hs
+++ /dev/null
@@ -1,46 +0,0 @@
-{-
- *  Programmer:	Piotr Borek
- *  E-mail:     piotrborek@op.pl
- *  Copyright 2015 Piotr Borek
- *
- *  Distributed under the terms of the GPL (GNU Public License)
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
--}
-
-module Coin.Utils.LocaleHelper where
-
-import Text.I18N.GetText
-import System.Directory
-import System.Locale.SetLocale
-import System.FilePath
-
-import Coin.Utils.FileHelper
-
-initLocale :: String -> String -> IO ()
-initLocale programName filePath = do
-    exePath <- findExecutable programName
-    curDir  <- getCurrentDirectory
-
-    _ <- setLocale LC_ALL $ Just ""
-    _ <- case exePath of
-            Just path -> do
-                let (exeDir, _) = separateFilePath path
-                bindTextDomain programName (Just $ exeDir </> filePath)
-            Nothing   ->
-                bindTextDomain programName (Just $ curDir </> filePath)
-    _ <- textDomain $ Just programName
-
-    return ()
diff --git a/src/Main.hs b/src/Main.hs
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -22,20 +22,16 @@
 
 module Main (main) where
 
-import System.FilePath
 import Graphics.UI.Gtk
 
 import Coin.UI.MainState
 import Coin.UI.MainWindow
 import Coin.UI.MainInitialize
-import Coin.Utils.LocaleHelper
 
 import Coin.DB.Tables
 
 main :: IO ()
 main = do
-    initLocale "coin" $ "resources" </> "i18n"
-
     initializeDatabase
 
     _ <- initGUI
