private async void OpenDocument()
        {
            if (OpenFileDialog(openFileDialog) != null)
            {
                PathToDoc = openFileDialog.FileName;

                FontStats.Clear();
                int count = TextStat.HowMuchLettersICanHide(PathToDoc);
                var stats = await TextStat.GetFontStat(PathToDoc);

                foreach (var st in stats)
                {
                    FontStats.Add(new FontInfo(st.Key, st.Value, count));
                }
            }
        }
        private async void OpenDocument()
        {
            if (OpenFileDialog(openFileDialog) != null)
            {
                FullPathToOrigFile = openFileDialog.FileName;
                filenameOrigFile   = openFileDialog.SafeFileName;
                pathToDirOrigFile  = fullPathToOrigFile.Substring(0, fullPathToOrigFile.Length - filenameOrigFile.Length);

                FontStats.Clear();
                int count = TextStat.HowMuchLettersICanHide(fullPathToOrigFile);
                var stats = await TextStat.GetFontStat(fullPathToOrigFile);

                foreach (var st in stats)
                {
                    FontStats.Add(new FontInfo(st.Key, st.Value, count));
                }

                count /= 8;
                CountLettersIsCanHide = count.ToString();
                maxLettersIsCanHide   = Int32.Parse(countLettersIsCanHide);

                if (Int32.Parse(countLettersIsCanHide) > 0)
                {
                    IsTextForHideEnabled           = true;
                    IsHideInformationButtonEnabled = true;

                    RandomCheckBox.IsEnabled          = true;
                    RSACheckBox.IsEnabled             = true;
                    AdditionalBitsCheckBox.IsEnabled  = true;
                    VisibleColorCheckBox.IsEnabled    = true;
                    SmartHidingCheckBox.IsEnabled     = true;
                    AttributeHidingCheckBox.IsEnabled = true;

                    HashingMD5CheckBox.IsEnabled    = true;
                    HashingSHA512CheckBox.IsEnabled = true;
                    AESCheckBox.IsEnabled           = true;
                    TwoFishCheckBox.IsEnabled       = true;

                    ShifrElGamalCheckBox.IsEnabled = true;
                }
                else
                {
                    ShowMetroMessageBox("Ошибка", "В данном файле невозможно скрыть информацию.");
                }
            }
        }