C# Class Bloom.Collection.CollectionSettings

A library corresponds to a single folder (with subfolders) on the disk. In that folder is a file which persists the properties of this class, then a folder for each book
Afficher le fichier Open project: BloomBooks/BloomDesktop Class Usage Examples

Méthodes publiques

Свойство Type Description
PageNumberStyleKeys string[]

Private Properties

Свойство Type Description
AddFontCssRule void
AddNumberingStyleCssRule void
DoOneTimeCheck void
GetBoolValue bool
GetDecimalValue decimal
GetDefaultFontName string
GetIntegerValue int
GetLanguage1Name_NoCache string
GetLanguageNameInUILangIfPossible string
GetValue string
MakeLanguageUploadData Bloom.Book.LanguageDescriptor[]
MigrateSettingsToAndikaNewBasicFont bool
SaveSettingsCollectionStylesCss void

Méthodes publiques

Méthode Description
CollectionSettings ( ) : System

for moq in unit tests only

CollectionSettings ( NewCollectionSettings collectionInfo ) : System
CollectionSettings ( string desiredOrExistingSettingsFilePath ) : System

can be used whether the library exists already, or not

CreateNewCollection ( NewCollectionSettings collectionInfo ) : void
FindSettingsFileInFolder ( string folderPath ) : string
GetLanguage1Name ( string inLanguage ) : string
GetLanguage2Name ( string inLanguage ) : string
GetLanguage3Name ( string inLanguage ) : string
GetLanguageLineHeight ( int langNum ) : decimal
GetLanguageName ( string code, string inLanguage ) : string

Get the name of the language whose code is the first argument, if possible in the language specified by the second. If the language code is unknown, return it unchanged.

GetLanguageRtl ( int langNum ) : bool
GetPathForNewSettings ( string parentFolderPath, string newCollectionName ) : string
Load ( ) : void
RenameCollection ( string fromDirectory, string toDirectory ) : string
Save ( ) : void
SetLanguageLineHeight ( int langNum, decimal lineHeight ) : void
SetLanguageRtl ( int langNum, bool isRtl ) : void

Private Methods

Méthode Description
AddFontCssRule ( StringBuilder sb, string selector, string fontName, decimal lineHeight ) : void
AddNumberingStyleCssRule ( StringBuilder sb, string styleNameKey ) : void
DoOneTimeCheck ( ) : void
GetBoolValue ( System.Xml.Linq.XElement library, string id, bool defaultValue ) : bool
GetDecimalValue ( System.Xml.Linq.XElement library, string id, decimal defaultValue ) : decimal
GetDefaultFontName ( ) : string
GetIntegerValue ( System.Xml.Linq.XElement library, string id, int defaultValue ) : int
GetLanguage1Name_NoCache ( string inLanguage ) : string
GetLanguageNameInUILangIfPossible ( string name, string codeOfDesiredLanguage ) : string
GetValue ( System.Xml.Linq.XElement document, string id, string defaultValue ) : string
MakeLanguageUploadData ( string isoCodes ) : Bloom.Book.LanguageDescriptor[]
MigrateSettingsToAndikaNewBasicFont ( ) : bool
SaveSettingsCollectionStylesCss ( ) : void

Method Details

CollectionSettings() public méthode

for moq in unit tests only
public CollectionSettings ( ) : System
Résultat System

CollectionSettings() public méthode

public CollectionSettings ( NewCollectionSettings collectionInfo ) : System
collectionInfo NewCollectionSettings
Résultat System

CollectionSettings() public méthode

can be used whether the library exists already, or not
public CollectionSettings ( string desiredOrExistingSettingsFilePath ) : System
desiredOrExistingSettingsFilePath string
Résultat System

CreateNewCollection() public static méthode

public static CreateNewCollection ( NewCollectionSettings collectionInfo ) : void
collectionInfo NewCollectionSettings
Résultat void

FindSettingsFileInFolder() public static méthode

public static FindSettingsFileInFolder ( string folderPath ) : string
folderPath string
Résultat string

GetLanguage1Name() public méthode

public GetLanguage1Name ( string inLanguage ) : string
inLanguage string
Résultat string

GetLanguage2Name() public méthode

public GetLanguage2Name ( string inLanguage ) : string
inLanguage string
Résultat string

GetLanguage3Name() public méthode

public GetLanguage3Name ( string inLanguage ) : string
inLanguage string
Résultat string

GetLanguageLineHeight() public méthode

public GetLanguageLineHeight ( int langNum ) : decimal
langNum int
Résultat decimal

GetLanguageName() public méthode

Get the name of the language whose code is the first argument, if possible in the language specified by the second. If the language code is unknown, return it unchanged.
public GetLanguageName ( string code, string inLanguage ) : string
code string
inLanguage string
Résultat string

GetLanguageRtl() public méthode

public GetLanguageRtl ( int langNum ) : bool
langNum int
Résultat bool

GetPathForNewSettings() public static méthode

public static GetPathForNewSettings ( string parentFolderPath, string newCollectionName ) : string
parentFolderPath string
newCollectionName string
Résultat string

Load() public méthode

public Load ( ) : void
Résultat void

RenameCollection() public static méthode

public static RenameCollection ( string fromDirectory, string toDirectory ) : string
fromDirectory string
toDirectory string
Résultat string

Save() public méthode

public Save ( ) : void
Résultat void

SetLanguageLineHeight() public méthode

public SetLanguageLineHeight ( int langNum, decimal lineHeight ) : void
langNum int
lineHeight decimal
Résultat void

SetLanguageRtl() public méthode

public SetLanguageRtl ( int langNum, bool isRtl ) : void
langNum int
isRtl bool
Résultat void

Property Details

PageNumberStyleKeys public_oe static_oe property

public static string[] PageNumberStyleKeys
Résultat string[]