Mercurial > projects > dstep
diff dstep/corefoundation/CFLocale.d @ 11:07194b026fa4
Added bindings to a couple of frameworks, new license + some other things
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Sat, 01 Aug 2009 15:03:28 +0200 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/dstep/corefoundation/CFLocale.d Sat Aug 01 15:03:28 2009 +0200 @@ -0,0 +1,69 @@ +/** + * Copyright: Copyright (c) 2009 Jacob Carlborg. + * Authors: Jacob Carlborg + * Version: Initial created: Jul 12, 2009 + * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0) + */ +module dstep.corefoundation.CFLocale; + +import dstep.corefoundation.CFArray; +import dstep.corefoundation.CFBase; +import dstep.corefoundation.CFDictionary; +import dstep.objc.bridge.Bridge; +import dstep.objc.objc : id; + +struct __CFLocale; +alias __CFLocale* CFLocaleRef; + +extern (C) +{ + extern + { + const CFStringRef kCFLocaleCurrentLocaleDidChangeNotification; + const CFStringRef kCFLocaleIdentifier; + const CFStringRef kCFLocaleLanguageCode; + const CFStringRef kCFLocaleCountryCode; + const CFStringRef kCFLocaleScriptCode; + const CFStringRef kCFLocaleVariantCode; + const CFStringRef kCFLocaleExemplarCharacterSet; + const CFStringRef kCFLocaleCalendarIdentifier; + const CFStringRef kCFLocaleCalendar; + const CFStringRef kCFLocaleCollationIdentifier; + const CFStringRef kCFLocaleUsesMetricSystem; + const CFStringRef kCFLocaleMeasurementSystem; + const CFStringRef kCFLocaleDecimalSeparator; + const CFStringRef kCFLocaleGroupingSeparator; + const CFStringRef kCFLocaleCurrencySymbol; + const CFStringRef kCFLocaleCurrencyCode; + const CFStringRef kCFGregorianCalendar; + const CFStringRef kCFBuddhistCalendar; + const CFStringRef kCFChineseCalendar; + const CFStringRef kCFHebrewCalendar; + const CFStringRef kCFIslamicCalendar; + const CFStringRef kCFIslamicCivilCalendar; + const CFStringRef kCFJapaneseCalendar; + } +} + +extern (C) +{ + uint CFLocaleGetTypeID (); + CFLocaleRef CFLocaleGetSystem (); + CFLocaleRef CFLocaleCopyCurrent (); + CFArrayRef CFLocaleCopyAvailableLocaleIdentifiers (); + CFArrayRef CFLocaleCopyISOLanguageCodes (); + CFArrayRef CFLocaleCopyISOCountryCodes (); + CFArrayRef CFLocaleCopyISOCurrencyCodes (); + CFArrayRef CFLocaleCopyCommonISOCurrencyCodes (); + CFArrayRef CFLocaleCopyPreferredLanguages (); + CFStringRef CFLocaleCreateCanonicalLanguageIdentifierFromString (CFAllocatorRef allocator, CFStringRef localeIdentifier); + CFStringRef CFLocaleCreateCanonicalLocaleIdentifierFromString (CFAllocatorRef allocator, CFStringRef localeIdentifier); + CFStringRef CFLocaleCreateCanonicalLocaleIdentifierFromScriptManagerCodes (CFAllocatorRef allocator, short lcode, short rcode); + CFDictionaryRef CFLocaleCreateComponentsFromLocaleIdentifier (CFAllocatorRef allocator, CFStringRef localeID); + CFStringRef CFLocaleCreateLocaleIdentifierFromComponents (CFAllocatorRef allocator, CFDictionaryRef dictionary); + CFLocaleRef CFLocaleCreate (CFAllocatorRef allocator, CFStringRef localeIdentifier); + CFLocaleRef CFLocaleCreateCopy (CFAllocatorRef allocator, CFLocaleRef locale); + CFStringRef CFLocaleGetIdentifier (CFLocaleRef locale); + void* CFLocaleGetValue (CFLocaleRef locale, CFStringRef key); + CFStringRef CFLocaleCopyDisplayNameForPropertyValue (CFLocaleRef displayLocale, CFStringRef key, CFStringRef value); +} \ No newline at end of file