Skip to content

Localization library that support localize views from storyBoard and RTL/LTR Languages support and localize Fonts

License

Notifications You must be signed in to change notification settings

mohshaat1990/Localization

Repository files navigation

LocalizationLib

  • support RTL/LTR language
  • support localization from StoryBoard
  • support Image RTL from StoryBoard
  • change Language without Restarting Application
  • localize Fonts by substitute font

Installation

using pods

pod 'LocalizableLib'

Usage

ezgif com-video-to-gif

import LocalizableLib

// for left to right language

MoLocalization.set(lang: "ar",
isRightToLeft: true,
forceReset: true,
startStoryBorad: "Main",
startViewController: "ViewController")

// for right to left language

MoLocalization.set(lang: "en",
isRightToLeft: false,
forceReset: true,
startStoryBorad: "Main",
startViewController: "ViewController")

to get current Language

MoLocalization.currentAppleLanguage()

localizable programmatically

// localizable programmatically

lbl.text = "changeLanguage".localized()

Change Font Global

import LocalizableLib

if MoLocalization.currentAppleLanguage() == "ar" {
UITextField.appearance().substituteFontName = "Arial"
UILabel.appearance().substituteFontName = "Arial"
UILabel.appearance().substituteFontNameBold = "Arial-Bold"
UITextField.appearance().substituteFontNameBold = "Arial-Bold"
}

About

Localization library that support localize views from storyBoard and RTL/LTR Languages support and localize Fonts

Resources

License

Stars

Watchers

Forks

Packages

No packages published