Recent

Author Topic: System language  (Read 1588 times)

vladimirr

  • New Member
  • *
  • Posts: 21
System language
« on: February 28, 2019, 09:43:08 am »
Hi! How to get default system language?


Thaddy

  • Hero Member
  • *****
  • Posts: 10110
Re: System language
« Reply #1 on: February 28, 2019, 10:05:30 am »
formatsettings
I am more like donkey than shrek

wp

  • Hero Member
  • *****
  • Posts: 7067
Re: System language
« Reply #2 on: February 28, 2019, 10:31:47 am »
Call either GetLanguageIDs(var Lang, FallbackLang: string) (in unit GetText) or LazGetLanguageIDs(var Lang, FallbackLang: string) (in unit LazUTF8); the latter is an extension of the first one to work also in Darwin.
Lazarus trunk / fpc 3.0.4 / all 32-bit on Win-10

vladimirr

  • New Member
  • *
  • Posts: 21
Re: System language
« Reply #3 on: March 05, 2019, 12:04:02 pm »
Call either GetLanguageIDs(var Lang, FallbackLang: string) (in unit GetText) or LazGetLanguageIDs(var Lang, FallbackLang: string) (in unit LazUTF8); the latter is an extension of the first one to work also in Darwin.

Thank you! I've found one more - LazGetShortLanguageID() // returns "en", "ru"..

 

TinyPortal © 2005-2018