Esempio n. 1
0
 private void OnAppDailyNumbersChanged(object _ = null)
 {
     DispatchQueue.MainQueue.DispatchAsync(() => {
         _dailyNumbersButton.AccessibilityLabel = _viewModel.NewDailyNumbersAccessibilityText;
         StyleUtil.InitLabelWithSpacing(dailyNumbersUpdatedLbl, StyleUtil.FontType.FontRegular, InfectionStatusViewModel.INFECTION_STATUS_DAILY_NUMBERS_LAST_UPDATED_TEXT, 1.14, 12, 16);
     });
 }
 void SetStyling()
 {
     StyleUtil.InitLabelWithSpacing(TitleLbl, StyleUtil.FontType.FontBold, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_HEADER_TEXT, 1.14, 32, 38);
     StyleUtil.InitLabelWithSpacing(SubtitleLbl, StyleUtil.FontType.FontRegular, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_INFORMATION_TEXT, 1.28, 20, 22);
     StyleUtil.InitLabelWithSpacing(ListExplainLbl, StyleUtil.FontType.FontRegular, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_FOOTER, 1.28, 16, 20);
     StyleUtil.InitButtonStyling(NextBtn, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_BUTTON_TEXT);
     SetButtonViewStyle();
 }
Esempio n. 3
0
 public SettingsPageContentLabel(IntPtr handle) : base(handle)
 {
     Lines     = 100;
     TextColor = UIColor.White;
     TranslatesAutoresizingMaskIntoConstraints = false;
     TextColor = UIColor.White;
     StyleUtil.InitLabelWithSpacing(this, FontType.FontRegular, Text ?? "", 1.28, 16, 22);
 }
Esempio n. 4
0
 void SetStyling()
 {
     StyleUtil.InitLabelWithSpacing(TitleLbl, StyleUtil.FontType.FontBold, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_HEADER_TEXT, 1.14, 24, 38);
     StyleUtil.InitLabelWithSpacing(SubtitleLbl, StyleUtil.FontType.FontRegular, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_INFORMATION_TEXT, 1.28, 16, 20);
     StyleUtil.InitLabelWithSpacing(ListExplainLbl, StyleUtil.FontType.FontRegular, QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_FOOTER, 1.28, 16, 20);
     NextBtn.SetTitle(QuestionnaireCountriesViewModel.COUNTRY_QUESTIONAIRE_BUTTON_TEXT, UIControlState.Normal);
     ButtonView.Alpha           = 0.9f;
     ButtonView.BackgroundColor = "#001F34".ToUIColor();
 }
Esempio n. 5
0
 public void Update(MessageItemViewModel message)
 {
     StyleUtil.InitLabelWithSpacing(Label1, StyleUtil.FontType.FontRegular, message.Title, 1.14, 16, 28);
     StyleUtil.InitLabelWithSpacing(Label2, StyleUtil.FontType.FontRegular, DateUtils.GetDateFromDateTime(message.TimeStamp, "d. MMMMM"), 1.14, 12, 17);
     StyleUtil.InitLabelWithSpacing(Label3, StyleUtil.FontType.FontRegular, MessageItemViewModel.MESSAGES_RECOMMENDATIONS, 1.14, 12, 17);
     IndicatorView.Alpha              = message.IsRead ? 0 : 1;
     this.BackgroundColor             = message.IsRead ? new UIColor(new nfloat(1), new nfloat(0.1)) : new UIColor(new nfloat(1), new nfloat(0.25));
     IndicatorView.Layer.CornerRadius = IndicatorView.Layer.Frame.Height / 2;
 }
Esempio n. 6
0
 private void SetStyling()
 {
     StyleUtil.InitLabelWithSpacing(Label, StyleUtil.FontType.FontBold, MESSAGES_HEADER, 1.14, 24, 36);
     StyleUtil.InitLabelWithSpacing(LabelLastUpdate, StyleUtil.FontType.FontRegular, LastUpdateString, 1.14, 12, 14, UITextAlignment.Left);
     StyleUtil.InitLabelWithSpacing(NoItemsLabel1, StyleUtil.FontType.FontRegular, MESSAGES_NO_ITEMS_TITLE, 1.14, 16, 18);
     StyleUtil.InitLabelWithSpacing(NoItemsLabel2, StyleUtil.FontType.FontRegular, MESSAGES_NO_ITEMS_DESCRIPTION, 1.14, 12, 14, UITextAlignment.Left);
     BackButton.AccessibilityLabel = SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON;
     SetLogoBasedOnAppLanguage();
 }
Esempio n. 7
0
 private void SetStyling()
 {
     TitleLabel.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_HEADER);
     TitleLabel.AccessibilityLabel = QuestionnaireViewModel.REGISTER_QUESTIONAIRE_ACCESSIBILITY_RECEIPT_HEADER;
     ContentLabelOne.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_TEXT);
     ContentLabelTwo.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_DESCRIPTION);
     BoxTitleLabel.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_INNER_HEADER, StyleUtil.FontType.FontBold);
     StyleUtil.InitLabelWithSpacing(BoxContentLabelTwo, StyleUtil.FontType.FontRegular, QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_INNER_READ_MORE, 1.28, 12, 16);
     StyleUtil.InitButtonStyling(ToStartPageBtn, QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_DISMISS);
 }
 private void SetStyling()
 {
     CloseButton.TintColor = ColorHelper.PRIMARY_COLOR;
     TitleLabel.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_HEADER);
     ContentLabelOne.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_TEXT);
     ContentLabelTwo.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_DESCRIPTION);
     BoxTitleLabel.SetAttributedText(QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_INNER_HEADER,
                                     StyleUtil.FontType.FontBold);
     StyleUtil.InitLabelWithSpacing(BoxContentLabelTwo, StyleUtil.FontType.FontRegular,
                                    QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_INNER_READ_MORE, 1.28, 12, 16);
     StyleUtil.InitButtonStyling(ToStartPageBtn, QuestionnaireViewModel.REGISTER_QUESTIONAIRE_RECEIPT_DISMISS);
 }
Esempio n. 9
0
        public void UpdateCell(CountryDetailsViewModel country)
        {
            StyleUtil.InitLabelWithSpacing(CountryNameLabel, StyleUtil.FontType.FontRegular, country.Name, 1.14, 16, 28);
            CheckboxImage.Image = (country.Checked ? UIImage.FromBundle("CheckboxChecked") : UIImage.FromBundle("CheckboxUnchecked"));

            if (country.Checked)
            {
                AccessibilityTraits |= UIAccessibilityTrait.Selected;
            }
            else
            {
                AccessibilityTraits &= ~UIAccessibilityTrait.Selected;
            }
        }
Esempio n. 10
0
 public void Update(MessageItemViewModel message)
 {
     StyleUtil.InitLabelWithSpacing(Label1, StyleUtil.FontType.FontMedium, message.Title.Translate(), 1.14, 18, 28);
     StyleUtil.InitLabelWithSpacing(Label2, StyleUtil.FontType.FontRegular, DateUtils.GetDateFromDateTime(message.TimeStamp, "d. MMMMM"), 1.14, 15, 17);
     StyleUtil.InitLabelWithSpacing(Label3, StyleUtil.FontType.FontRegular, MessageItemViewModel.MESSAGES_RECOMMENDATIONS, 1.14, 15, 17);
     StyleUtil.InitLabelWithSpacing(UnreadLabel, StyleUtil.FontType.FontBold, MessagesViewModel.MESSAGES_NEW_ITEM, 1.14, 15, 17);
     if (message.IsRead)
     {
         IndicatorView.Hidden = true;
         UnreadLabel.Hidden   = true;
         Label2.LeadingAnchor.ConstraintEqualTo(Label3.LeadingAnchor).Active = true;
     }
     this.BackgroundColor = message.IsRead ? new UIColor(new nfloat(1), new nfloat(0.1)) : new UIColor(new nfloat(1), new nfloat(0.25));
 }
        public void Update(MessageItemViewModel message)
        {
            if (AppDelegate.ShouldOperateIn12_5Mode)
            {
                IndicatorView.BackgroundColor    = UIColor.Red;
                IndicatorView.Layer.CornerRadius = IndicatorView.Layer.Frame.Height / 2;
            }

            StyleUtil.InitLabelWithSpacing(Label1, StyleUtil.FontType.FontMedium, message.Title.Translate(), 1.14, 18, 28);
            StyleUtil.InitLabelWithSpacing(Label2, StyleUtil.FontType.FontRegular, DateUtils.GetDateFromDateTime(message.TimeStamp, "d. MMMMM"), 1.14, 15, 17);
            StyleUtil.InitLabelWithSpacing(Label3, StyleUtil.FontType.FontRegular, MessageItemViewModel.MESSAGES_RECOMMENDATIONS, 1.14, 15, 17);
            StyleUtil.InitLabelWithSpacing(UnreadLabel, StyleUtil.FontType.FontBold, MessagesViewModel.MESSAGES_NEW_ITEM, 1.14, 15, 17);
            if (message.IsRead)
            {
                IndicatorView.Hidden = true;
                UnreadLabel.Hidden   = true;
                Label2.LeadingAnchor.ConstraintEqualTo(Label3.LeadingAnchor).Active = true;
            }
            this.BackgroundColor = UIColor.Clear;
        }
Esempio n. 12
0
        private async void SetStyling()
        {
            StyleUtil.InitLabelWithSpacing(Label, StyleUtil.FontType.FontBold, MESSAGES_HEADER, 0.8, 22, 34);
            StyleUtil.InitLabelWithSpacing(LabelLastUpdate, StyleUtil.FontType.FontRegular, LastUpdateString, 1.14, 15, 17, UITextAlignment.Left);
            int    unreadMessages = (await MessageUtils.GetAllUnreadMessages()).Count;
            int    messages       = (await MessageUtils.GetMessages()).Count;
            string headerText     = MESSAGES_NO_ITEMS_TITLE;

            if (unreadMessages > 0)
            {
                headerText = MESSAGES_NEW_MESSAGES_HEADER;
            }
            else if (messages > 0)
            {
                headerText = MESSAGES_NO_NEW_MESSAGES_HEADER;
            }
            StyleUtil.InitLabelWithSpacing(NoItemsLabel1, StyleUtil.FontType.FontBold, headerText, 1, 32, 34);
            StyleUtil.InitLabelWithSpacing(NoItemsLabel2, StyleUtil.FontType.FontRegular, MESSAGES_NO_ITEMS_DESCRIPTION, 1.25, 18, 20, UITextAlignment.Left);
            BackButton.AccessibilityLabel = SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON;
        }
Esempio n. 13
0
        public override void ViewDidLoad()
        {
            base.ViewDidLoad();

            string contentText = SettingsPage5ViewModel.SETTINGS_PAGE_5_CONTENT + " " + SettingsPage5ViewModel.SETTINGS_PAGE_5_LINK;

            HeaderLabel.SetAttributedText(SettingsPage5ViewModel.SETTINGS_PAGE_5_HEADER);

            StyleUtil.InitTextViewWithSpacing(ContentText, FontType.FontRegular, contentText, 1.28, 16, 22);

            //ForegroundColor sets the color of the links. UnderlineStyle determins if the link is underlined, 0 without underline 1 with underline.
            ContentText.WeakLinkTextAttributes = new NSDictionary(UIStringAttributeKey.ForegroundColor, ColorHelper.TEXT_COLOR_ON_BACKGROUND, UIStringAttributeKey.UnderlineStyle, new NSNumber(1));

            StyleUtil.InitLabelWithSpacing(BuildVersionLbl, FontType.FontRegular, SettingsPage5ViewModel.GetVersionInfo(), 1.14, 14, 16);
            BackButton.AccessibilityLabel = SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON;

            ContentText.AccessibilityIdentifier      = "contentTextIdentifier";
            ContentText.IsAccessibilityElement       = true;
            ContentText.AccessibilityAttributedLabel = AccessibilityUtils.RemovePoorlySpokenSymbols(contentText);

            SetupStyling();
        }
Esempio n. 14
0
        private void SetStyling()
        {
            // Set background color and corner radius for views
            DailyNumbersView1.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView1.Layer.CornerRadius  = 12;
            DailyNumbersView2.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView2.Layer.CornerRadius  = 12;
            DailyNumbersView3.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView3.Layer.CornerRadius  = 12;
            DailyNumbersView4.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView4.Layer.CornerRadius  = 12;
            DailyNumbersView7.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView7.Layer.CornerRadius  = 12;
            DailyNumbersView8.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView8.Layer.CornerRadius  = 12;
            DailyNumbersView9.BackgroundColor     = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView9.Layer.CornerRadius  = 12;
            DailyNumbersView10.BackgroundColor    = ColorHelper.PRIMARY_COLOR;
            DailyNumbersView10.Layer.CornerRadius = 12;


            // Labels dependable on device width
            double width   = Xamarin.Essentials.DeviceDisplay.MainDisplayInfo.Width;
            int    fontMin = width <= 700 ? 22 : 27;
            int    fontMax = width <= 700 ? 24 : 29;

            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber1Lbl, StyleUtil.FontType.FontBold, ConfirmedCasesToday, 1.14, fontMin, fontMax);
            DailyNumbersNumber1Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber3Lbl, StyleUtil.FontType.FontBold, TestsConductedToday, 1.14, fontMin, fontMax);
            DailyNumbersNumber3Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber4Lbl, StyleUtil.FontType.FontBold, PatientsAdmittedToday, 1.14, fontMin, fontMax);
            DailyNumbersNumber4Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber5Lbl, StyleUtil.FontType.FontBold, NumberOfPositiveTestsResultsLast7Days, 1.14, fontMin, fontMax);
            DailyNumbersNumber5Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber6Lbl, StyleUtil.FontType.FontBold, SmittestopDownloadsTotal, 1.14, fontMin, fontMax);
            DailyNumbersNumber6Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber7Lbl, StyleUtil.FontType.FontBold, PatientsIntensiveCare, 1.14, fontMin, fontMax);
            DailyNumbersNumber7Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber9Lbl, StyleUtil.FontType.FontBold, VaccinationsDoseOneToday, 1.14, fontMin, fontMax);
            DailyNumbersNumber9Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            StyleUtil.InitLabelWithSpacing(DailyNumbersNumber10Lbl, StyleUtil.FontType.FontBold, VaccinationsDoseTwoToday, 1.14, fontMin, fontMax);
            DailyNumbersNumber10Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            // Labels not dependable on device width
            StyleUtil.InitLabelWithSpacing(DailyNumbersTitleOne, StyleUtil.FontType.FontBold, DAILY_NUMBERS_HEADER, 1.14, 30, 36);
            DailyNumbersTitleOne.AccessibilityTraits = UIAccessibilityTrait.Header;

            StyleUtil.InitLabelWithSpacing(DailyNumbersLbl, StyleUtil.FontType.FontBold, DAILY_NUMBERS_TITLE_ONE, 1.14, 20, 36);
            DailyNumbersLbl.AccessibilityTraits = UIAccessibilityTrait.Header;
            SetupSubTextWithLink(LastUpdateStringSubHeader, DailyNumbersOfTheDayTextLbl);
            DailyNumbersOfTheDayTextLbl.WeakDelegate = new OpenTextViewUrlInWebviewDelegate(this);

            StyleUtil.InitLabelWithSpacing(KeyFeature1Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_ONE_LABEL, 1.14, 16, 18);
            StyleUtil.InitLabelWithSpacing(TotalDailyNumbersNumber1Lbl, StyleUtil.FontType.FontRegular, ConfirmedCasesTotal, 1.14, 12, 14);
            KeyFeature1Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            TotalDailyNumbersNumber1Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(TotalDailyNumbersNumber3Lbl, StyleUtil.FontType.FontRegular, TestsConductedTotal, 1.14, 12, 14);
            StyleUtil.InitLabelWithSpacing(KeyFeature3Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_THREE_LABEL, 1.14, 16, 18);
            KeyFeature3Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            TotalDailyNumbersNumber3Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(KeyFeature4Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_FOUR_LABEL, 1.14, 16, 18);
            KeyFeature4Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(KeyFeature6Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_SIX_LABEL, 1.14, 16, 18);
            KeyFeature6Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(KeyFeature5Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_FIVE_LABEL, 1.14, 16, 18);
            StyleUtil.InitLabelWithSpacing(TotalDailyNumbersNumber5Lbl, StyleUtil.FontType.FontRegular, NumberOfPositiveTestsResultsTotal, 1.14, 12, 14);
            KeyFeature5Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            TotalDailyNumbersNumber5Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(KeyFeature7Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_SEVEN_LABEL, 1.14, 16, 18);
            KeyFeature7Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(DailyNumbersTitleTwo, StyleUtil.FontType.FontBold, DAILY_NUMBERS_TITLE_TWO, 1.14, 20, 36);
            SetupSubTextWithLink(LastUpdateStringSubTextTwo, DailyNumbersSubtextTwo);
            DailyNumbersSubtextTwo.WeakDelegate      = new OpenTextViewUrlInWebviewDelegate(this);
            DailyNumbersTitleTwo.AccessibilityTraits = UIAccessibilityTrait.Header;

            StyleUtil.InitLabelWithSpacing(KeyFeature9Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_NINE_LABEL, 1.14, 16, 18);
            KeyFeature9Lbl.AccessibilityLabel = KEY_FEATURE_NINE_ACCESSIBILITY_LABEL;
            StyleUtil.InitLabelWithSpacing(TotalDailyNumbersNumber9Lbl, StyleUtil.FontType.FontRegular, VaccinationsDoseOneTotal, 1.14, 12, 14);
            KeyFeature9Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            TotalDailyNumbersNumber9Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(KeyFeature10Lbl, StyleUtil.FontType.FontRegular, KEY_FEATURE_TEN_LABEL, 1.14, 16, 18);
            KeyFeature10Lbl.AccessibilityLabel = KEY_FEATURE_TEN_ACCESSIBILITY_LABEL;
            StyleUtil.InitLabelWithSpacing(TotalDailyNumbersNumber10Lbl, StyleUtil.FontType.FontRegular, VaccinationsDoseTwoTotal, 1.14, 12, 14);
            KeyFeature10Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;
            TotalDailyNumbersNumber10Lbl.TextColor = ColorHelper.TEXT_COLOR_ON_PRIMARY;

            StyleUtil.InitLabelWithSpacing(DailyNumbersTitleThree, StyleUtil.FontType.FontBold, DAILY_NUMBERS_TITLE_THREE, 1.14, 20, 36);
            SetupSubTextWithLink(LastUpdateStringSubSubHeader, DailyNumbersSubSubHeader);
            DailyNumbersSubSubHeader.WeakDelegate      = new OpenTextViewUrlInWebviewDelegate(this);
            DailyNumbersTitleThree.AccessibilityTraits = UIAccessibilityTrait.Header;

            //Setting up accessibility grouping
            Statistics_StackView.ShouldGroupAccessibilityChildren              = true;
            Vaccinations_StackView.ShouldGroupAccessibilityChildren            = true;
            Smittestopp_StackView.ShouldGroupAccessibilityChildren             = true;
            ConfirmedCases_StackView.ShouldGroupAccessibilityChildren          = true;
            NumberOfTests_StackView.ShouldGroupAccessibilityChildren           = true;
            PatientsAdmitted_StackView.ShouldGroupAccessibilityChildren        = true;
            TotalDownloads_StackView.ShouldGroupAccessibilityChildren          = true;
            NumberOfPositiveResults_StackView.ShouldGroupAccessibilityChildren = true;
            VaccinationsDose1_StackView.ShouldGroupAccessibilityChildren       = true;
            VaccinationsDose2_StackView.ShouldGroupAccessibilityChildren       = true;

            // Back button styling and accessibility
            BackButton.AccessibilityLabel = BACK_BUTTON_ACCESSIBILITY_TEXT;

            //Implemented for correct voiceover due to smitte|stop, removing pronunciation of lodretstreg
            KeyFeature5Lbl.AccessibilityAttributedLabel = AccessibilityUtils.RemovePoorlySpokenSymbols(KEY_FEATURE_FIVE_LABEL);
        }
Esempio n. 15
0
 /// <summary>
 /// When using this method the label is styled using StyleUtil.InitLabelWithSpacing()
 /// </summary>
 /// <param name="text"></param>
 public void SetAttributedText(string text, FontType fontType = FontType.FontRegular)
 {
     Text = text;
     StyleUtil.InitLabelWithSpacing(this, fontType, text, 1.28, 16, 22);
 }
Esempio n. 16
0
        async void ShowPickerController()
        {
            SetRecursiveInteraction(View, false);
            View.AddSubview(SpinnerMainView);
            // Make sure accessibility is enabled for the whole view
            SpinnerMainView.AccessibilityElementsHidden = false;
            SpinnerMainView.UserInteractionEnabled      = true;

            // Disable accessibility for the subviews to prevent focus stealing
            SpinnerDialogButton.AccessibilityElementsHidden = true;
            SpinnerDialogButton.UserInteractionEnabled      = false;
            Picker.AccessibilityElementsHidden               = true;
            Picker.UserInteractionEnabled                    = false;
            SpinnerDialogTitle.AccessibilityElementsHidden   = true;
            SpinnerDialogTitle.UserInteractionEnabled        = false;
            SpinnerDialogMessage.AccessibilityElementsHidden = true;
            SpinnerDialogMessage.UserInteractionEnabled      = false;

            StyleUtil.InitLabelWithSpacing(
                SpinnerDialogTitle,
                StyleUtil.FontType.FontBold,
                INFECTION_STATUS_PAUSE_DIALOG_TITLE,
                1.14,
                24,
                38,
                true);
            StyleUtil.InitLabelWithSpacing(
                SpinnerDialogMessage,
                StyleUtil.FontType.FontRegular,
                INFECTION_STATUS_PAUSE_DIALOG_MESSAGE,
                1.28,
                16,
                20,
                true);
            SpinnerDialogButton.SetTitle(
                INFECTION_STATUS_PAUSE_DIALOG_OK_BUTTON,
                UIControlState.Normal);

            SpinnerDialogTitle.AccessibilityAttributedLabel =
                AccessibilityUtils.RemovePoorlySpokenSymbols(INFECTION_STATUS_PAUSE_DIALOG_TITLE);
            SpinnerDialogMessage.AccessibilityAttributedLabel =
                AccessibilityUtils.RemovePoorlySpokenSymbols(INFECTION_STATUS_PAUSE_DIALOG_MESSAGE);
            SpinnerDialogButton.AccessibilityAttributedLabel =
                AccessibilityUtils.RemovePoorlySpokenSymbols(INFECTION_STATUS_PAUSE_DIALOG_OK_BUTTON);

            Picker.Model = new HoursPickerModel(
                new List <string> {
                INFECTION_STATUS_PAUSE_DIALOG_OPTION_NO_REMINDER,
                INFECTION_STATUS_PAUSE_DIALOG_OPTION_ONE_HOUR,
                INFECTION_STATUS_PAUSE_DIALOG_OPTION_TWO_HOURS,
                INFECTION_STATUS_PAUSE_DIALOG_OPTION_FOUR_HOURS,
                INFECTION_STATUS_PAUSE_DIALOG_OPTION_EIGHT_HOURS
            });

            SpinnerMainView.Hidden = false;
            SetFocusTo(SpinnerDialogTitle, () =>
            {
                SpinnerDialogButton.AccessibilityElementsHidden = false;
                SpinnerDialogButton.UserInteractionEnabled      = true;
                Picker.AccessibilityElementsHidden               = false;
                Picker.UserInteractionEnabled                    = true;
                SpinnerDialogTitle.AccessibilityElementsHidden   = false;
                SpinnerDialogTitle.UserInteractionEnabled        = true;
                SpinnerDialogMessage.AccessibilityElementsHidden = false;
                SpinnerDialogMessage.UserInteractionEnabled      = true;
            });
        }
Esempio n. 17
0
 public ENDeveloperToolsOutputData(IntPtr handle) : base(handle)
 {
     Lines = 100;
     TranslatesAutoresizingMaskIntoConstraints = false;
     StyleUtil.InitLabelWithSpacing(this, FontType.FontRegular, Text ?? "", 1.28, 16, 22);
 }
Esempio n. 18
0
 public SetttingsPageTitleLabel(IntPtr handle) : base(handle)
 {
     Lines     = 100;
     TextColor = UIColor.White;
     StyleUtil.InitLabelWithSpacing(this, StyleUtil.FontType.FontBold, Text ?? "", 1.14, 24, 26);
 }
Esempio n. 19
0
 /// <summary>
 /// When using this method the label is styled using StyleUtil.InitLabelWithSpacing()
 /// </summary>
 /// <param name="text"></param>
 public void SetAttributedText(string text)
 {
     Text = text;
     StyleUtil.InitLabelWithSpacing(this, StyleUtil.FontType.FontBold, text, 1.14, 24, 26);
 }