What is the difference between NSFont and UIFont

1.4k views Asked by At

While searching the solution of a problem I found the NSFont and UIFont both,

whats the basic difference between both and when should we use?

3

There are 3 answers

0
rckoenes On

NSFont is part of AppKit which is the UI library for MacOS.

UIFont is part of UIKit which is the UI library for iOS.

0
cole On

Apple documentation for appkit uikit

Apple documentation for nsfont

It is pretty clear that they both are part of different framework.

0
iamsankalp89 On

If you are using macOS the use NSFont

and for iOS you will use UiFont