mmApp Class

Application class for Markdown Monster that provides a global static placeholder for configuration and some utility functions

System.Object
   MarkdownMonster.mmApp

Class Members

MemberDescription
Constructor
ApplicationStart
public void ApplicationStart()
CompareVersions Compare two version strings.
public int CompareVersions(string versionToCompare, string versionToCompareAgainst)
DecryptString Decrypts a string encrypted with EncryptString()
public string DecryptString(string encrypted, Nullable dontUseMachineKey)
EncryptString Encrypts sensitive user data using an internally generated encryption key.
public string EncryptString(string value)
GetDocumentionUrl Returns a fully qualified Help URL to a topic in the online documentation based on a topic id.
public string GetDocumentionUrl(string topic)
GetMachineHardwareInfo Get Machine Name and Model that allows to determine whether the machine is a virtual machine
public string GetMachineHardwareInfo()
GetNewLine Return LineFeed for the application
public string GetNewLine()
GetVersion Gets the Markdown Monster Version as a string
public string GetVersion()
GetVersionDate Return the write date for the Main MM application executable
public string GetVersionDate()
GetVersionForDisplay Returns a formatted string value for the version.
public string GetVersionForDisplay(string version)
HandleApplicationException Handles an Application level exception by logging the error to log, and displaying an error message to the user. Also sends the error to server if enabled. Returns true if application should…
public bool HandleApplicationException(Exception ex, ApplicationErrorModes errorMode)
InitializeLogging Starts the Application Insights logging functionality Note: this should be set on application startup once and will not fire multiple times.
public void InitializeLogging()
Log Logs messages to the standard log output for Markdown Monster: * Application Insights * Local Log File
public void Log(Exception ex, LogLevels logLevel)
public void Log(string msg, Exception ex, bool unhandledException, LogLevels logLevel)
LogInfo Logs an information message
public void LogInfo(string msg, LogLevels logLevel)
LogLocal This method logs only to the local file, not to the online telemetry. Use primarily for informational messages and errors.
public void LogLocal(string msg, Exception ex)
LogTrace Writes a trace message
public void LogTrace(string msg, LogLevels logLevel)
SetTheme Sets the light or dark theme for a form. Call before InitializeComponents(). We only support the dark theme now so this no longer relevant but left in place in case we decide to support other themes.
public void SetTheme(Themes theme, MetroWindow window)
SetThemeWindowOverride Overrides specific colors in the active theme depending on the currently active theme. Use this in every Metro Window form to apply base window styling. Affects: * Title Brush, Active Title Brush *…
public void SetThemeWindowOverride(MetroWindow window, bool isMainWindow, string forceTheme)
SetWorkingSet
public void SetWorkingSet(int lnMaxSize, int lnMinSize)
Shutdown
public void Shutdown(bool errorShutdown)
ShutdownLogging Shuts down the Application Insights Logging functionality and flushes any pending requests. This handles start and stop times and the application lifetime log entry that logs duration of operation.
public void ShutdownLogging()
WriteUseCount
public void WriteUseCount(int count, bool dontAssignValue)
AllowedFileExtensions
ApplicationName The full name of the application displayed on toolbar and dialogs
Configuration Holds a static instance of the application's configuration settings
Constants
EncryptionMachineKey Returns a machine specific encryption key that can be used for passwords and other settings. If the Configuration.UseMachineEcryptionKeyForPasswords flag is false, no machine specific information is…
GlobalConfiguration Explicit global configuration property, that unlike `Configuration` always returns the global configuration.
InternalMachineKey Internal Machine Key which is a registry GUID value
InternalUseCount
IsCli Determines whether the application is running in non-UI mode
IsShutdown
Model Holds a static instance of the Application Model
NewLine
OpenAiConnection Open AI Connection - can be null or check `IsEmpty`. This connection is set from the OpenAiAddinConfiguration
OpenWindows A static class that holds singleton window references
PostFix
Signature
Started
Urls Application related Urls used throughout the application
WebViewRuntimeVersion
WebViewSdkVersion
Window Shortcut to the main app window
Namespace: MarkdownMonster

Assembly: MarkdownMonster.dll



© West Wind Technologies, 2025 • Updated: 2025-02-25
Comment or report problem with topic