public DocumentController(MainController mainController, Document document)
		{
			this.mainController = mainController;
			this.document = document;

			documentProperties = (DocumentProperties) document.CustomDocumentProperties;

			var documentStyleTitle = GetDocumentStyleTitle();
			style = mainController.FindStyleByTitle(documentStyleTitle) ?? mainController.DefaultStyle;
		}
		void AddinModule_AddinStartupComplete(object sender, EventArgs e)
		{
			try
			{
				mainController = new MainController(this);
			}
			catch (Exception ex)
			{
				LogException(ex);
			}
		}
		void AddinModule_AddinStartupComplete(object sender, EventArgs e)
		{
			try
			{
				mainController = new MainController(this);

				rbRefresh.PropertyChanging += OnRefreshPropertyChanging;
			}
			catch (Exception ex)
			{
				LogException(ex);
			}
		}