Posts

Showing posts from April, 2019

iOS Tutorial - Easy and flexible custom fonts in the runtime without so much code !

Image
Problem:  You may find your app needs custom fonts but in many different ways and a lot of fonts  fonts can change the whole user experience of an application even making the user prefer one application to another in android for example : they have a powerful font system you can declare your custom fonts in the xml file and you can even inherit one font from another  in This tutorial we gonna make the ios easier to customize even in the story board  the final result you will be able to write the name of custom font in interface builder inspector to be applied in the runtime You can type "TSRegularLight_small" in text_style field of a button or label applies to it  #1st step:  Create the enums to represent your font sizes, fonts and font type(bold, italic etc)  enum UIFontSizes   : Int {     case xSmall = 12     case small = 14     case large = ...

iOS Tutorial - The standard login screen but in rx and mvvm !

Image
In this tutorial we gonna explain how mvvm can be used along with rx What is MVVM pattern? Model . (M) Model  refers either to a  domain model , which represents real state content (an object-oriented approach), or to the  data access layer , which represents content (a data-centric approach). [ citation needed ] View (V) As in the  model-view-controller  (MVC) and  model-view-presenter  (MVP) patterns, the  view  is the structure, layout, and appearance of what a user sees on the screen. [6]  It displays a representation of the model and receives the user's interaction with the view (clicks, keyboard, gestures, etc.), and it forwards the handling of these to the view model via the  data binding  (properties, event callbacks, etc.) that is defined to link the view and view model. View model (VM) The  view model  is an abstraction of the view exposing public properties and commands. Instead o...