MagickCore
7.0.10
|
#include "MagickCore/studio.h"
#include "MagickCore/blob.h"
#include "MagickCore/client.h"
#include "MagickCore/configure.h"
#include "MagickCore/exception.h"
#include "MagickCore/exception-private.h"
#include "MagickCore/image-private.h"
#include "MagickCore/linked-list.h"
#include "MagickCore/locale_.h"
#include "MagickCore/locale-private.h"
#include "MagickCore/log.h"
#include "MagickCore/memory_.h"
#include "MagickCore/memory-private.h"
#include "MagickCore/nt-base-private.h"
#include "MagickCore/semaphore.h"
#include "MagickCore/splay-tree.h"
#include "MagickCore/string_.h"
#include "MagickCore/string-private.h"
#include "MagickCore/token.h"
#include "MagickCore/utility.h"
#include "MagickCore/utility-private.h"
#include "MagickCore/xml-tree.h"
#include "MagickCore/xml-tree-private.h"
Go to the source code of this file.
Macros | |
#define | LocaleFilename "locale.xml" |
Functions | |
static MagickBooleanType | IsLocaleTreeInstantiated (ExceptionInfo *) |
static MagickBooleanType | LoadLocaleCache (SplayTreeInfo *, const char *, const char *, const char *, const size_t, ExceptionInfo *) |
static void * | DestroyLocaleNode (void *locale_info) |
static SplayTreeInfo * | AcquireLocaleSplayTree (const char *filename, const char *locale, ExceptionInfo *exception) |
static void * | DestroyOptions (void *message) |
MagickExport LinkedListInfo * | DestroyLocaleOptions (LinkedListInfo *messages) |
MagickPrivate ssize_t | FormatLocaleFileList (FILE *file, const char *magick_restrict format, va_list operands) |
MagickExport ssize_t | FormatLocaleFile (FILE *file, const char *magick_restrict format,...) |
MagickPrivate ssize_t | FormatLocaleStringList (char *magick_restrict string, const size_t length, const char *magick_restrict format, va_list operands) |
MagickExport ssize_t | FormatLocaleString (char *magick_restrict string, const size_t length, const char *magick_restrict format,...) |
MagickExport const LocaleInfo * | GetLocaleInfo_ (const char *tag, ExceptionInfo *exception) |
static int | LocaleInfoCompare (const void *x, const void *y) |
MagickExport const LocaleInfo ** | GetLocaleInfoList (const char *pattern, size_t *number_messages, ExceptionInfo *exception) |
static int | LocaleTagCompare (const void *x, const void *y) |
MagickExport char ** | GetLocaleList (const char *pattern, size_t *number_messages, ExceptionInfo *exception) |
MagickExport const char * | GetLocaleMessage (const char *tag) |
MagickExport LinkedListInfo * | GetLocaleOptions (const char *filename, ExceptionInfo *exception) |
MagickExport const char * | GetLocaleValue (const LocaleInfo *locale_info) |
MagickExport double | InterpretLocaleValue (const char *magick_restrict string, char **magick_restrict sentinal) |
MagickExport MagickBooleanType | ListLocaleInfo (FILE *file, ExceptionInfo *exception) |
static void | ChopLocaleComponents (char *path, const size_t components) |
static void | LocaleFatalErrorHandler (const ExceptionType magick_unused(severity), const char *reason, const char *description) |
MagickExport int | LocaleCompare (const char *p, const char *q) |
MagickExport void | LocaleLower (char *string) |
MagickExport int | LocaleLowercase (const int c) |
MagickExport int | LocaleNCompare (const char *p, const char *q, const size_t length) |
MagickExport void | LocaleUpper (char *string) |
MagickExport int | LocaleUppercase (const int c) |
MagickPrivate MagickBooleanType | LocaleComponentGenesis (void) |
MagickPrivate void | LocaleComponentTerminus (void) |
Variables | |
static const char * | LocaleMap |
static SemaphoreInfo * | locale_semaphore = (SemaphoreInfo *) NULL |
static SplayTreeInfo * | locale_cache = (SplayTreeInfo *) NULL |
#define LocaleFilename "locale.xml" |
Definition at line 72 of file locale.c.
Referenced by IsLocaleTreeInstantiated().
|
static |
Definition at line 185 of file locale.c.
References CompareSplayTreeString(), DestroyLocaleNode(), DestroyLocaleOptions(), GetLocaleOptions(), GetNextValueInLinkedList(), GetNumberOfNodesInSplayTree(), GetStringInfoDatum(), GetStringInfoPath(), LoadLocaleCache(), LocaleMap, MagickTrue, and NewSplayTree().
Referenced by IsLocaleTreeInstantiated().
|
static |
Definition at line 1105 of file locale.c.
Referenced by LoadLocaleCache().
|
static |
Definition at line 170 of file locale.c.
References DestroyString(), _LocaleInfo::message, _LocaleInfo::path, RelinquishMagickMemory(), and _LocaleInfo::tag.
Referenced by AcquireLocaleSplayTree().
MagickExport LinkedListInfo* DestroyLocaleOptions | ( | LinkedListInfo * | messages | ) |
Definition at line 293 of file locale.c.
References DestroyLinkedList(), DestroyOptions(), GetMagickModule, LogMagickEvent(), and TraceEvent.
Referenced by AcquireLocaleSplayTree().
|
static |
Definition at line 288 of file locale.c.
References DestroyStringInfo().
Referenced by DestroyLocaleOptions().
MagickExport ssize_t FormatLocaleFile | ( | FILE * | file, |
const char *magick_restrict | format, | ||
... | |||
) |
Definition at line 372 of file locale.c.
References FormatLocaleFileList().
Referenced by AcquireResizeFilter(), AutoThresholdImage(), Classify(), CloseMagickLog(), DefaultErrorHandler(), DefaultFatalErrorHandler(), DefaultWarningHandler(), DestroyLogElement(), DistortImage(), ExternalDelegateCommand(), FxEvaluateSubexpression(), GetNumberColors(), IdentifyImage(), KmeansImage(), ListCoderInfo(), ListColorInfo(), ListCommandOptions(), ListConfigureInfo(), ListDelegateInfo(), ListLocaleInfo(), ListLogInfo(), ListMagicInfo(), ListMagickInfo(), ListMagickResourceInfo(), ListMagickVersion(), ListMimeInfo(), ListPolicyInfo(), ListThresholdMapFile(), ListThresholdMaps(), ListTypeInfo(), LocaleFatalErrorHandler(), LockSemaphoreInfo(), LogMagickEventList(), MorphologyApply(), OptimizeLayerFrames(), ParseKernelName(), PrintChannelFeatures(), PrintChannelLocations(), PrintChannelMoments(), PrintChannelPerceptualHash(), PrintChannelStatistics(), PrintStringInfo(), RenderPostscript(), ResamplePixelColor(), ScaleGeometryKernelInfo(), ScaleResampleFilter(), ShowKernelInfo(), SparseColorImage(), and UnlockSemaphoreInfo().
MagickPrivate ssize_t FormatLocaleFileList | ( | FILE * | file, |
const char *magick_restrict | format, | ||
va_list | operands | ||
) |
Definition at line 327 of file locale.c.
Referenced by FormatLocaleFile().
MagickExport ssize_t FormatLocaleString | ( | char *magick_restrict | string, |
const size_t | length, | ||
const char *magick_restrict | format, | ||
... | |||
) |
Definition at line 467 of file locale.c.
References FormatLocaleStringList().
Referenced by AcquireTypeCache(), AnnotateImage(), AppendImageFormat(), AutoThresholdImage(), BlobToImage(), BlurImage(), CannyEdgeImage(), CanonicalXMLContent(), ClipImagePath(), ClonePixelCacheRepository(), ColorMatrixImage(), ConcatenateColorComponent(), ConcatentateHexColorComponent(), ConnectPixelCacheServer(), CustomStreamToImage(), DeskewImage(), DestroyPixelCache(), DistortImage(), DrawPatternPath(), DrawPrimitive(), EncodePredefinedEntities(), FormatMagickSize(), FormatMagickTime(), FxChannelStatistics(), GaussianBlurImage(), GetConfigureOptions(), GetConfigurePaths(), GetExecutionPath(), GetEXIFProperty(), GetLocaleExceptionMessage(), GetLocaleMessage(), GetLocaleOptions(), GetMagickHomeURL(), GetMagickProperty(), GetMagickPropertyLetter(), GetPageGeometry(), GetPathTemplate(), GetStructuralSimilarityDistortion(), HoughLineImage(), IdentifyImage(), ImagesToBlob(), ImagesToCustomStream(), ImageToBlob(), ImageToCustomStream(), InjectImageBlob(), InterpretImageFilename(), InterpretImageProperties(), InvokeDelegate(), ListMagickResourceInfo(), ListTypeInfo(), LogPixelChannels(), MagickToMime(), MontageImageList(), MorphologyApply(), OpenBlob(), OpenPixelCache(), PingBlob(), PolaroidImage(), PreviewImage(), RenderMVGContent(), RenderPostscript(), SelectiveBlurImage(), SetImageProgress(), SetPixelCacheExtent(), StringToStrings(), ThrowMagickExceptionList(), ThumbnailImage(), TraceBezierCurve(), TracePSClippath(), TraceSVGClippath(), TranslateEvent(), TranslateFilename(), VignetteImage(), XMLTreeInfoToXML(), and XMLTreeTagToXML().
MagickPrivate ssize_t FormatLocaleStringList | ( | char *magick_restrict | string, |
const size_t | length, | ||
const char *magick_restrict | format, | ||
va_list | operands | ||
) |
Definition at line 418 of file locale.c.
Referenced by FormatLocaleString().
MagickExport const LocaleInfo* GetLocaleInfo_ | ( | const char * | tag, |
ExceptionInfo * | exception | ||
) |
Definition at line 508 of file locale.c.
References GetNextValueInSplayTree(), GetValueFromSplayTree(), IsLocaleTreeInstantiated(), locale_cache, locale_semaphore, LocaleCompare(), LockSemaphoreInfo(), MagickFalse, ResetSplayTreeIterator(), and UnlockSemaphoreInfo().
Referenced by GetLocaleInfoList(), GetLocaleList(), and GetLocaleMessage().
MagickExport const LocaleInfo** GetLocaleInfoList | ( | const char * | pattern, |
size_t * | number_messages, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 581 of file locale.c.
References AcquireQuantumMemory(), GetLocaleInfo_(), GetMagickModule, GetNextValueInSplayTree(), GetNumberOfNodesInSplayTree(), GlobExpression(), locale_cache, locale_semaphore, LocaleInfoCompare(), LockSemaphoreInfo(), LogMagickEvent(), MagickFalse, MagickTrue, ResetSplayTreeIterator(), _LocaleInfo::stealth, _LocaleInfo::tag, TraceEvent, and UnlockSemaphoreInfo().
Referenced by ListLocaleInfo().
MagickExport char** GetLocaleList | ( | const char * | pattern, |
size_t * | number_messages, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 676 of file locale.c.
References AcquireQuantumMemory(), ConstantString(), GetLocaleInfo_(), GetMagickModule, GetNextValueInSplayTree(), GetNumberOfNodesInSplayTree(), GlobExpression(), locale_cache, locale_semaphore, LocaleTagCompare(), LockSemaphoreInfo(), LogMagickEvent(), MagickFalse, MagickTrue, _LocaleInfo::stealth, _LocaleInfo::tag, TraceEvent, and UnlockSemaphoreInfo().
MagickExport const char* GetLocaleMessage | ( | const char * | tag | ) |
Definition at line 741 of file locale.c.
References AcquireExceptionInfo(), DestroyExceptionInfo(), FormatLocaleString(), GetLocaleInfo_(), MagickLocaleExtent, and _LocaleInfo::message.
Referenced by GetLocaleExceptionMessage().
MagickExport LinkedListInfo* GetLocaleOptions | ( | const char * | filename, |
ExceptionInfo * | exception | ||
) |
Definition at line 789 of file locale.c.
References AcquireStringInfo(), AppendValueToLinkedList(), ConfigureFileToStringInfo(), CopyMagickString(), DestroyLinkedList(), FormatLocaleString(), GetConfigurePaths(), GetMagickModule, GetNextValueInLinkedList(), LocaleEvent, LogMagickEvent(), MagickPathExtent, NewLinkedList(), RelinquishMagickMemory(), ResetLinkedListIterator(), SetStringInfoDatum(), SetStringInfoLength(), SetStringInfoPath(), and TraceEvent.
Referenced by AcquireLocaleSplayTree().
MagickExport const char* GetLocaleValue | ( | const LocaleInfo * | locale_info | ) |
Definition at line 874 of file locale.c.
References GetMagickModule, LogMagickEvent(), MagickCoreSignature, _LocaleInfo::message, _LocaleInfo::signature, and TraceEvent.
MagickExport double InterpretLocaleValue | ( | const char *magick_restrict | string, |
char **magick_restrict | sentinal | ||
) |
Definition at line 971 of file locale.c.
Referenced by GetDrawValue(), InterpretSiPrefixValue(), ParsePixelChannelOption(), StringToDouble(), and StringToDoubleInterval().
|
static |
Definition at line 905 of file locale.c.
References AcquireLocaleSplayTree(), ActivateSemaphoreInfo(), ConstantString(), DestroyString(), GetEnvironmentValue(), locale_cache, locale_semaphore, LocaleFilename, LockSemaphoreInfo(), MagickFalse, MagickTrue, and UnlockSemaphoreInfo().
Referenced by GetLocaleInfo_().
MagickExport MagickBooleanType ListLocaleInfo | ( | FILE * | file, |
ExceptionInfo * | exception | ||
) |
Definition at line 1026 of file locale.c.
References FormatLocaleFile(), GetLocaleInfoList(), LocaleCompare(), MagickFalse, MagickTrue, _LocaleInfo::path, and RelinquishMagickMemory().
static MagickBooleanType LoadLocaleCache | ( | SplayTreeInfo * | cache, |
const char * | xml, | ||
const char * | filename, | ||
const char * | locale, | ||
const size_t | depth, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1144 of file locale.c.
References AcquireCriticalMemory(), AcquireString(), AddValueToSplayTree(), ChopLocaleComponents(), ConcatenateMagickString(), ConfigureError, ConfigureEvent, ConstantString(), CopyMagickString(), DestroyString(), DirectorySeparator, FileToXML(), GetMagickModule, GetNextToken(), GetPathComponent(), HeadPath, LocaleCompare(), LocaleFatalErrorHandler(), LocaleNCompare(), LogMagickEvent(), MagickCoreSignature, MagickFalse, MagickLocaleExtent, MagickMaxRecursionDepth, MagickMin, MagickPathExtent, MagickTrue, _LocaleInfo::message, _LocaleInfo::path, RelinquishMagickMemory(), ResourceLimitError, SetFatalErrorHandler(), _LocaleInfo::signature, _LocaleInfo::tag, and ThrowMagickException().
Referenced by AcquireLocaleSplayTree().
MagickExport int LocaleCompare | ( | const char * | p, |
const char * | q | ||
) |
Definition at line 1403 of file locale.c.
References LocaleLowercase().
Referenced by AcquireStreamPixels(), AcquireVirtualMemory(), AppendImageFormat(), CoalesceImages(), CoderCompare(), CoderInfoCompare(), ColorCompare(), ColorInfoCompare(), CompareSplayTreeString(), ConfigureCompare(), ConfigureInfoCompare(), DelegateCompare(), DelegateInfoCompare(), DrawPrimitive(), ExpandFilenames(), ExportCharPixel(), ExportDoublePixel(), ExportFloatPixel(), ExportLongLongPixel(), ExportLongPixel(), ExportQuantumPixel(), ExportShortPixel(), FileCompare(), FileToBlob(), FileToImage(), FileToXML(), FxEvaluateSubexpression(), FxGetSymbol(), Get8BIMProperty(), GetCoderInfo(), GetColorCompliance(), GetCommandOptionFlags(), GetCommandOptionInfo(), GetConfigureInfo(), GetDelegateInfo(), GetEXIFProperty(), GetImageBoundingBox(), GetImageMinimumBoundingBox(), GetLocaleInfo_(), GetLogInfo(), GetMagickInfo(), GetMagickProperty(), GetMVGMacros(), GetPolicyInfo(), GetQuantumInfo(), GetThresholdMapFile(), GetTypeInfo(), GetTypeInfoByFamily(), GlobExpression(), GradientImage(), HuffmanEncodeImage(), IdentifyImage(), ImageToFile(), ImportCharPixel(), ImportDoublePixel(), ImportFloatPixel(), ImportLongLongPixel(), ImportLongPixel(), ImportQuantumPixel(), ImportShortPixel(), InvokeDelegate(), InvokeDynamicImageFilter(), IsOptionMember(), IsPathAccessible(), IsSkipTag(), IsStringFalse(), IsStringTrue(), IsTaintImage(), ListCoderInfo(), ListColorInfo(), ListConfigureInfo(), ListDelegateInfo(), ListFiles(), ListLocaleInfo(), ListLogInfo(), ListMagicInfo(), ListPolicyInfo(), ListTypeInfo(), LoadColorCache(), LoadConfigureCache(), LoadDelegateCache(), LoadLocaleCache(), LoadLogCache(), LoadPolicyCache(), LoadTypeCache(), LocaleInfoCompare(), LocaleTagCompare(), LogCompare(), LogInfoCompare(), MagicCompare(), MagicInfoCompare(), MagickCompare(), MagickInfoCompare(), MagnifyImage(), MontageImageList(), OpenBlob(), OpenPixelCache(), ParseCommandOption(), ParseKernelArray(), PatchCorruptProfile(), PingImages(), ProfileImage(), QueryColorCompliance(), ReadImage(), ReadImages(), RegisterStaticModule(), RenderMVGContent(), RenderType(), SetImageInfo(), SetImageOption(), SetImageProfileInternal(), SetImageProperty(), SetMagickSecurityPolicyValue(), SetPolicyValue(), StreamImagePixels(), ThrowException(), ThumbnailImage(), TranslateEvent(), TypeCompare(), TypeInfoCompare(), UnregisterMagickInfo(), UnregisterStaticModule(), WriteImage(), and WriteTo8BimProfile().
MagickPrivate MagickBooleanType LocaleComponentGenesis | ( | void | ) |
Definition at line 1637 of file locale.c.
References AcquireSemaphoreInfo(), locale_semaphore, and MagickTrue.
Referenced by MagickCoreGenesis().
MagickPrivate void LocaleComponentTerminus | ( | void | ) |
Definition at line 1665 of file locale.c.
References ActivateSemaphoreInfo(), DestroySplayTree(), locale_cache, locale_semaphore, LockSemaphoreInfo(), RelinquishSemaphoreInfo(), and UnlockSemaphoreInfo().
Referenced by MagickCoreTerminus().
|
static |
Definition at line 1128 of file locale.c.
References FormatLocaleFile(), GetClientName(), and magick_unreferenced.
Referenced by LoadLocaleCache().
|
static |
Definition at line 564 of file locale.c.
References LocaleCompare().
Referenced by GetLocaleInfoList().
MagickExport void LocaleLower | ( | char * | string | ) |
Definition at line 1447 of file locale.c.
References LocaleLowercase().
Referenced by GetColorTuple(), GetMagickProperty(), MagickToMime(), QueryColorCompliance(), SetImageProfileInternal(), and ThumbnailImage().
MagickExport int LocaleLowercase | ( | const int | c | ) |
Definition at line 1479 of file locale.c.
Referenced by GlobExpression(), LocaleCompare(), LocaleLower(), LocaleNCompare(), and StoreToken().
MagickExport int LocaleNCompare | ( | const char * | p, |
const char * | q, | ||
const size_t | length | ||
) |
Definition at line 1527 of file locale.c.
References LocaleLowercase().
Referenced by DrawPrimitive(), FxChannelStatistics(), FxEvaluateSubexpression(), FxGetSymbol(), FxOperatorPrecedence(), GetGeometry(), GetImageProperty(), GetMagickProperty(), GetNextToken(), GetPageGeometry(), GetProfilesFromResourceBlock(), InterpretDelegateProperties(), InterpretImageFilename(), InterpretImageProperties(), IsFxFunction(), LoadColorCache(), LoadConfigureCache(), LoadDelegateCache(), LoadLocaleCache(), LoadLogCache(), LoadPolicyCache(), LoadTypeCache(), OpenBlob(), ParseCSSColor(), ParseGeometry(), ParseLogHandlers(), PatchCorruptProfile(), QueryColorCompliance(), ReadInlineImage(), SetImageProperty(), and WriteTo8BimProfile().
|
static |
MagickExport void LocaleUpper | ( | char * | string | ) |
Definition at line 1576 of file locale.c.
References LocaleUppercase().
Referenced by InvokeDelegate(), and SetImageInfo().
MagickExport int LocaleUppercase | ( | const int | c | ) |
Definition at line 1608 of file locale.c.
Referenced by LocaleUpper(), and StoreToken().
|
static |
Definition at line 93 of file locale.c.
Referenced by GetLocaleInfo_(), GetLocaleInfoList(), GetLocaleList(), IsLocaleTreeInstantiated(), and LocaleComponentTerminus().
|
static |
Definition at line 90 of file locale.c.
Referenced by GetLocaleInfo_(), GetLocaleInfoList(), GetLocaleList(), IsLocaleTreeInstantiated(), LocaleComponentGenesis(), and LocaleComponentTerminus().
|
static |
Definition at line 78 of file locale.c.
Referenced by AcquireLocaleSplayTree().