grimoire

0.15.0-beta

Core

Core
Author: ltabis Declaration of the Core class.
Instance Members
get(pluginName)
register(plugin)
registerPlugin(plugin)

Core

new Core()
Instance Members
get(pluginName)
register(plugin)
registerPlugin(plugin)

GEditorType

All editor types available to the software.

GEditorType

GEditor

A class that contains data for an editor.

new GEditor()

GFileType

File types that can be found in a grimoires project.

GFileType

enumKeys

function used to easly fetch GFileType enum keys and values as text.

enumKeys(obj: any)
Parameters
obj (any)

GFile

Encapsulate a generic grimoire file. Is used when getting a projects source tree.

new GFile()

HashFile

A class that contains a hash property. It is used to store files has hashes.

new HashFile()

from

instanciate a new object from another set of data to copy or deserialize another place.

from(other: any)
Parameters
other (any)

type

get this agglomeration type translated in french.

type

from

instanciate a new object from another set of data to copy or deserialize another place.

from(other: any)
Parameters
other (any)

getPlaceIcon

fetch a static icon associated with a place that can be used to draw on the map's canvas.

getPlaceIcon(place: any)
Parameters
place (any)

Settings

Settings class, expose a container of sections containing settings.

new Settings()
Static Members
fromString(str)
Instance Members
get(section_name, param_name)

SettingsBuilder

A builder class used to easily initialize hardcoded settings.

new SettingsBuilder()
Instance Members
addSection(section_name)
addParameter(type, section_name, parameter_name, args)
build()

SheetType

All different types of sheet available for the character sheet editor.

SheetType

Sheet

A sheet is a data field that is displayed inside the character sheet editor. A box object contain multiple sheets.

new Sheet()

Box

A box object used to store and display data for a character in the character sheet editor.

new Box()

SheetTemplate

A sheet template is used to instantiate multiple sheets in a box. It can be used to prevent adding already existing patterns of sheets. For example, by default, an "identity" sheet template is loaded. It is used to create a character with basic informations easly without adding all sheets one by one.

new SheetTemplate()

DEFAULT_SHEET_TEMPLATE_MAP

this template map contains all basic data for a simple character.

DEFAULT_SHEET_TEMPLATE_MAP

Character

TODO: move this class into an appropriate ts file.

A character object contain all boxes and all sheets from a project's character. It is mainly used to store data using the config manager.

It inherites the HashFile class, this way it can be saved using it's own hash.

new Character()

ExternalPlugin

ExternalPlugin
Author: LangArthur Declaration of the ExternalPlugin class.

ICore

ICore
Author: ltabis Declaration of the Core interface.

Plugin

Plugin
Author: ltabis Declaration of the Plugin class.
Instance Members
setListeners()
name

Plugin

new Plugin(name: string, core: any, mandatory: boolean)
Parameters
name (string) A reference to the plugin manager.
core (any)
mandatory (boolean = true) Is the plugin required to function properly ?
Instance Members
setListeners()
name

config_manager

config_manager
Author: ltabis Declaration of the ConfigManager plugin.

DEFAULT_CONFIGURATION

DEFAULT_CONFIGURATION

DEFAULT_SETTINGS

DEFAULT_SETTINGS

DEFAULT_CONFIGURATION_LOCATION

DEFAULT_CONFIGURATION_LOCATION

DEFAULT_SETTINGS_LOCATION

DEFAULT_SETTINGS_LOCATION

ConfigManager

new ConfigManager()

Extends Plugin_1.Plugin

Instance Members
loadConfig()
addProject(projectPath)
deleteProjectFromConfig(path)
projects()
isProjectLoaded(path)
recent()
allowFontSearch()
setAllowFont(state)
addRecent(path)
removeOldestOpenedProject()
deleteRecentFromConfig(path)
store()
purge()
loadText(path)

context_menu

context_menu
Author: ltabis Declaration of the ContextMenu plugin.

ContextMenu

new ContextMenu()

Extends Plugin_1.Plugin

Instance Members
registerContextMenu(elementName, menu)

editor

editor
Author: Arthur Lang Declaration of the Editor plugin.

Editor

new Editor()

Extends Plugin_1.Plugin

Instance Members
insertCharacterToClipboard(character)
_confirmeClose(event, tabId)

error_manager

error_manager
Author: ltabis Declaration of the Editor plugin.

AppError

new AppError(message: any)

Extends Error

Parameters
message (any)

ConfigError

new ConfigError(message: any)

Extends Error

Parameters
message (any)

ProjectError

new ProjectError(message: any)

Extends Error

Parameters
message (any)
new MenuError(message: any)

Extends Error

Parameters
message (any)

EditorError

new EditorError(message: any)

Extends Error

Parameters
message (any)

ErrorManager

new ErrorManager()

Extends Plugin_1.Plugin

external_event_system

external_event_system
Author: Arthur Lang Declaration of a system to handle event from external plugins.

file_manager

file_manager
Author: ltabis Declaration of the FileManager plugin.

FileManager

new FileManager()

Extends Plugin_1.Plugin

Instance Members
getFilePath(filePath)
saveCurrentBuffer()
saveAllBuffers()
loadFromFile(filePath)
moveFile(oldPath, newPath)
loadIdeas()
loadTags()
loadToDoList()
getAllFiles(dirPath, fileArray)
getTextToExport(paths)
removeFile(file)
removeFileWithPath(path)
save(type, args)
saveText(filePath, content)
saveCharacterSheet(character)
saveChronology(events)
saveTodoList(tasks)
saveTag(tag)
loadChapter(dirPath, innerPath)
saveChapter(chapters, drafts)
saveSettings(raw)
saveMap(map)
savePostIt(postIts)
saveIdeas(ideas)
exportPDF(body)
createFolder(filepath)
createFile(filepath, content)
reloadSourceTree()
generateHashFile()

fonts_manager

fonts_manager
Author: Arthur Lang Declaration of the FontsManager plugin.

FontsManager

new FontsManager()

Extends Plugin_1.Plugin

Instance Members
_informUserFontUsed(finalMsg)
_askFonts(event, id)
_uploadContent()
_generateCss(font, fontNameEditor)
setFontList()
_readFonts()

grimoire_app

grimoire_app
Author: ltabis Declaration of the GrimoireApp plugin.

GrimoireApp

new GrimoireApp()

Extends Plugin_1.Plugin

Instance Members
_onReady()
_onActivate()
_onWindowAllClosed()
createFileProtocol()
createWindow()
_safeWindowQuit(event)
_confirmQuit(state)
_waitForSave(conditionFunction, maxIter)
activateSafeMode(activate)
loadPage(page)
quitApp(force)
window()
choosePath(title, message)
chooseFilePath(title, message, defaultPath)
isDarkModeActive()
setDarkMode()
takeScreenshot()
sendFeedback(email, feedback)
menu_manager
Author: ltabis Declaration of the MenuManager plugin.
new MenuManager()

Extends Plugin_1.Plugin

Instance Members

plugin_loader

plugin_loader
Author: LangArthur Load all plugins

project_manager

project_manager
Author: ltabis Declaration of the ProjectManager plugin.

ProjectManager

new ProjectManager()

Extends Plugin_1.Plugin

Instance Members
_onGetProjects(event)
_onDeleteProject(event, name)
_onImport(event)
_onValidateProjectCreationForm(event, title, genre, _importPath)
_onGetProjectSourceTree(event)
_onOpenProject(_event, projectName, event)
convertBytesToReadableFormat(bytes)
getAllFiles(dirPath, arrayOfFiles)
getTotalDirSize(directoryPath)
getProjectConfig(configPath)
getProjectScenario(configPath)
isTitleValid(title)
_projectExists(title)
_getProject(pathToProject)
createProject(title, genre)
getProjects()
searchProject()
deleteProject(name)
importFiles()
getProjectSourceTree(folderPath, projectSourceTree)
_getGrimoireFileType(fileName)
currentProjectPath()
currentResourcePath()
currentCharacterPath()
openProject(pathToProject)
_loadCharacters()

Counter

Counter
Author: Arthur Lang Declaration of the Counter quill plugin.

CustomImage

new CustomImage()

Extends Image

onCreate

onCreate()

_cropActivationCallback

_cropActivationCallback()

handleMousedown

handleMousedown(evt: MouseEvent)
Parameters
evt (MouseEvent) event trigger by the event.

handleDrag

handleDrag(evt: MouseEvent)
Parameters
evt (MouseEvent) event trigger by the event.

handleMouseup

handleMouseup()

hiddeSelector

hiddeSelector(cropState: boolean)
Parameters
cropState (boolean) if crop mode is activate or not.

_addCropSelector

_addCropSelector(cursor: string, selectorClass: string)
Parameters
cursor (string) type of cursor use for the selector
selectorClass (string) class of the selector. It is used for detecting with selector is clicked.

_positionSelector

_positionSelector()

isApplied

isApplied

_addButton

_addButton()

setCursor

setCursor(cursor: string)
Parameters
cursor (string) new cursor you want

_updateClipPath

_updateClipPath(clipPath: string)
Parameters
clipPath (string) the new clip path stringified.

changeTipTheme

changes the theme of tippy instance.

changeTipTheme(instance: Instance, theme: string)
Parameters
instance (Instance) tippy.js instance.
theme (string) the theme to apply.

changeTipsTheme

changes all themes from a set of tippy instance.

changeTipsTheme(instances: Array<Instance>, theme: string)
Parameters
instances (Array<Instance>) tippy.js instances.
theme (string) the theme to apply.

CharacterBoxAudio

CharacterBoxAudio

Extends vue_property_decorator_1.Mixins(AudioUploader_1.default)

CharacterList

CharacterList

Extends vue_property_decorator_1.Vue

CharBox

CharBox

Extends vue_property_decorator_1.Vue

CharBoxBar

CharBoxBar

Extends vue_property_decorator_1.Vue

CharBoxImage

CharBoxImage

Extends vue_property_decorator_1.Mixins(ImageUploader_1.default)

CharBoxLabel

CharBoxLabel

Extends vue_property_decorator_1.Vue

CharBoxParagraph

CharBoxParagraph

Extends vue_property_decorator_1.Vue

CharMinBox

CharMinBox

Extends vue_property_decorator_1.Vue

CharProfile

CharProfile

Extends vue_property_decorator_1.Mixins(ImageUploader_1.default)

EditorCharacterSheet

EditorCharacterSheet

Extends vue_property_decorator_1.Mixins(Editor_1.default)

updateTabName

updateTabName(name: string)
Parameters
name (string) new name you want to give to a tag. update the name of a tab.

TimeLineAudio

TimeLineAudio

Extends vue_property_decorator_1.Mixins(AudioUploader_1.default)

TimeLineElement

TimeLineElement

Extends vue_property_decorator_1.Vue

displayQuitButton

displayQuitButton(state: any)
Parameters
state (any) if the quit button have to be display on the event or not

isPeriod

isPeriod(): any
Returns
any: True if the element is a period

TimeLinePeriod

TimeLinePeriod

Extends vue_property_decorator_1.Vue

TimeLinePeriodSelector

TimeLinePeriodSelector

Extends vue_property_decorator_1.Vue

TimeLineText

TimeLineText

Extends vue_property_decorator_1.Vue

ChronologyEditor

ChronologyEditor

Extends vue_property_decorator_1.Mixins(Editor_1.default)

updateChapter

updateChapter(chap: any, eventId: any)
Parameters
chap (any) new chapter object
eventId (any) Id of the event to update

IdeaBox

IdeaBox

updateBody

updateBody(force: any)
Parameters
force (any) force a save, without timeout. save an idea. Note that there is a timeout to avoid too much saving

IdeasBoxEditor

IdeasBoxEditor

removeIdea

removeIdea(id: any)
Parameters
id (any) id of the idea to remove. remove an idea of the list.

removeIdea

removeIdea(id: any)
Parameters
id (any) id of the idea to remove. remove an idea of the list.

updateIdea

updateIdea(id: any)
Parameters
id (any) id of the idea to update. update an idea of the list and save the content.

tryConnectUser

Try to connect a user to the database.

! To be replaced with a database management with ! passwords stored as sha256.

tryConnectUser(login: string, password: string)
Parameters
login (string) The login of the user.
password (string) The password of the user.

PlaceMinCard

PlaceMinCard

Extends vue_property_decorator_1.Vue

updateColor

updateColor(color: any)
Parameters
color (any) VueColor object sent by the component update the color of the post-it

update

update(force: any)
Parameters
force (any) force a save, without timeout. save an idea. Note that there is a timeout to avoid too much saving

PostItContainer

PostItContainer

deletePostIt

deletePostIt(id: any)
Parameters
id (any) id of the post-it to remove remove a post-it to the list of post-it

updatePostIt

updatePostIt(postit: any)
Parameters
postit (any) post-it to update update the content of a post-it

movePostIt

movePostIt(id: any, xShift: any, yShift: any)
Parameters
id (any) id of the post-it to move.
xShift (any) shift in x dimension.
yShift (any) shift in y direction. change the position of the post-it.

sortProjects

Sort lines of the project table from the index of the header.

sortProjects(n: number)
Parameters
n (number) The index of the header to sort.

AudioUploader

AudioUploader

Extends vue_property_decorator_1.Vue

ImageUploader

ImageUploader

Extends vue_property_decorator_1.Vue

setContextMenuCallback

callback for context-menu events. register an event listener on an element, triggers a callback when '@contextmenu' is called.

setContextMenuCallback(name: string, element: HTMLElement, dataCallback: (ContextMenuDataCallback | null))
Parameters
name (string) the name of the element.
element (HTMLElement) the element to register events to.
dataCallback ((ContextMenuDataCallback | null) = null) a callback to provide data to the backend when '@contextmenu' is fired.