public ExpeditionControl() { InitializeComponent(); bool ADVANCED_MENUS = ConfigurationManager.Instance.ConfigurationRecord.GUI_AdvancedMenus; if (!ADVANCED_MENUS) ButtonRefresh.Caption = "Refresh\nExpedition"; ButtonRefresh.Icon = Icons.GetAppIcon(Icons.Refresh); ButtonRefresh.ToolTip = "Rebuild and refresh the Expedition database for this library.\nThis may take some time, but you can get on with other work in the meanwhile..."; ButtonRefresh.Click += ButtonRefresh_Click; if (!ADVANCED_MENUS) ButtonRefreshTags.Caption = "Refresh\nAutoTags"; ButtonRefreshTags.ToolTip = "Refresh AutoTags.\nPress this to automatically generate AutoTags for your documents. This may take some time but you can keep working in the meanwhile..."; ButtonRefreshTags.Icon = Icons.GetAppIcon(Icons.Refresh); ButtonRefreshTags.Click += ButtonRefreshTags_Click; if (!ADVANCED_MENUS) ButtonManageLists.Caption = "Manage\nAutoTags"; ButtonManageLists.ToolTip = "Manage your AutoTag black/whitelists.\nIf there are AutoTags you absolutely do or do not want Qiqqa to use, then you can add them here."; ButtonManageLists.Icon = Icons.GetAppIcon(Icons.LibraryAutoTagsBlackWhiteLists); ButtonManageLists.Click += ButtonManageLists_Click; if (!ADVANCED_MENUS) ButtonExportTopics.Caption = "Export\nThemes"; ButtonExportTopics.ToolTip = "Export a list of themes for your library."; ButtonExportTopics.Icon = Icons.GetAppIcon(Icons.ExportToText); ButtonExportTopics.Click += ButtonExportTopics_Click; ButtonCollapseAll.Icon = Icons.GetAppIcon(Icons.Minus); ButtonCollapseAll.IconHeight = 12; ButtonCollapseAll.IconWidth = 12; ButtonCollapseAll.ToolTip = "Collapse all topics"; ButtonCollapseAll.Click += ButtonCollapseAll_Click; ButtonExpandAll.Icon = Icons.GetAppIcon(Icons.Plus); ButtonExpandAll.IconHeight = 12; ButtonExpandAll.IconWidth = 12; ButtonExpandAll.ToolTip = "Expand all topics"; ButtonExpandAll.Click += ButtonExpandAll_Click; GridVote.Visibility = Visibility.Collapsed; VoteUp.Icon = Icons.GetAppIcon(Icons.ThumbsUp); VoteUp.Click += VoteUp_Click; VoteDown.Icon = Icons.GetAppIcon(Icons.ThumbsDown); VoteDown.Click += VoteDown_Click; TextLibraryForExpedition.IsReadOnly = true; TextLibraryForExpedition.PreviewMouseDown += TextLibraryForExpedition_PreviewMouseDown; TextLibraryForExpedition.ToolTip = "Click to choose a Library to use for your Expedition."; TextLibraryForExpedition.Cursor = Cursors.Hand; ObjDocumentOverviewControl.ObjExpeditionPaperSimilarsControl.PDFDocumentSelected += ObjDocumentOverviewControl_PDFDocumentSelected; Webcasts.FormatWebcastButton(ButtonWebcast, Webcasts.EXPEDITION); if (!ADVANCED_MENUS) ButtonWebcast.Caption = "Tutorial\n"; ChooseNewLibrary(null); }
public RegionWebcasts() { InitializeComponent(); Webcasts.FormatWebcaseHyperlink(LnkFirst10Mins, Webcasts.FIRST10MINS); Webcasts.FormatWebcaseHyperlink(LnkIdeas, Webcasts.IDEAS); Webcasts.FormatWebcaseHyperlink(LnkExplore, Webcasts.EXPLORE); Webcasts.FormatWebcaseHyperlink(LnkExternalIntro, Webcasts.EXTERNAL_BASICS); Webcasts.FormatWebcaseHyperlink(LnkLibrary, Webcasts.LIBRARY); Webcasts.FormatWebcaseHyperlink(LnkPDFViewer, Webcasts.PDF_VIEWER); Webcasts.FormatWebcaseHyperlink(LnkBrainstorm, Webcasts.BRAINSTORM); Webcasts.FormatWebcaseHyperlink(LnkExpedition, Webcasts.EXPEDITION); Webcasts.FormatWebcaseHyperlink(LnkBibTeXSniffer, Webcasts.BIBTEX_SNIFFER); Webcasts.FormatWebcaseHyperlink(LnkInCite, Webcasts.INCITE); Webcasts.FormatWebcaseHyperlink(LnkPlay, Webcasts.PLAY); ImageHelpers.Source = Icons.GetAppIcon(Icons.GlossHelpers, "jpg"); RenderOptions.SetBitmapScalingMode(ImageHelpers, BitmapScalingMode.HighQuality); MouseWheelDisabler.DisableMouseWheelForControl(ImageHelpers); HyperlinkForums.Click += HyperlinkForums_Click; }
public InCiteControl() { Theme.Initialize(); InitializeComponent(); // Tabs DualTabControlArea.Children.Clear(); DualTabControlArea.AddContent("Library", "Cite papers from your library", null, false, false, TabLibrary); DualTabControlArea.AddContent("Recommendations", "Cite papers recommended by Qiqqa InCite", null, false, false, TabRecommendations); DualTabControlArea.AddContent("Cluster", "Edit current citation cluster", null, false, false, TabCitationClusterEditor); DualTabControlArea.MakeActive("Library"); bool ADVANCED_MENUS = ConfigurationManager.Instance.ConfigurationRecord.GUI_AdvancedMenus; ButtonCitationSnippetToClipboard.Icon = Icons.GetAppIcon(Icons.InCiteCitationSnippet); if (!ADVANCED_MENUS) { ButtonCitationSnippetToClipboard.Caption = LocalisationManager.Get("INCITE/CAP/NEW_SNIPPET"); } ButtonCitationSnippetToClipboard.ToolTip = LocalisationManager.Get("INCITE/TIP/NEW_SNIPPET"); ButtonCitationSnippetToClipboard.Click += ButtonCitationSnippetToClipboard_Click; ButtonNewCitation.Icon = Icons.GetAppIcon(Icons.InCiteNewCitation); if (!ADVANCED_MENUS) { ButtonNewCitation.Caption = LocalisationManager.Get("INCITE/CAP/NEW_CITATION"); } ButtonNewCitation.ToolTip = LocalisationManager.Get("INCITE/TIP/NEW_CITATION"); ButtonNewCitation.Click += ButtonNewCitation_Click; ButtonNewCitationSeparateAuthorYear.Icon = Icons.GetAppIcon(Icons.InCiteNewCitation); if (!ADVANCED_MENUS) { ButtonNewCitationSeparateAuthorYear.Caption = LocalisationManager.Get("INCITE/CAP/NEW_CITATION_SEPARATE_AUTHOR_YEAR"); } ButtonNewCitationSeparateAuthorYear.ToolTip = LocalisationManager.Get("INCITE/TIP/NEW_CITATION_SEPARATE_AUTHOR_YEAR"); ButtonNewCitationSeparateAuthorYear.Click += ButtonNewCitationSeparateAuthorYear_Click; ButtonAddBibliography.Icon = Icons.GetAppIcon(Icons.InCiteAddBibliography); if (!ADVANCED_MENUS) { ButtonAddBibliography.Caption = LocalisationManager.Get("INCITE/CAP/NEW_BIBLIOGRAPHY"); } ButtonAddBibliography.ToolTip = LocalisationManager.Get("INCITE/TIP/NEW_BIBLIOGRAPHY"); ButtonAddBibliography.Click += ButtonAddBibliography_Click; ButtonRefresh.Icon = Icons.GetAppIcon(Icons.InCiteRefresh); if (!ADVANCED_MENUS) { ButtonRefresh.Caption = LocalisationManager.Get("INCITE/CAP/REFORMAT"); } ButtonRefresh.ToolTip = LocalisationManager.Get("INCITE/TIP/REFORMAT"); ButtonRefresh.Click += ButtonRefresh_Click; ButtonEditCSL.AttachPopup(ButtonEditCSLPopup); ButtonEditCSL.Icon = Icons.GetAppIcon(Icons.InCiteEditCSL); if (!ADVANCED_MENUS) { ButtonEditCSL.Caption = LocalisationManager.Get("INCITE/CAP/CSL_OPTIONS"); } ButtonCSLStandard.Icon = Icons.GetAppIcon(Icons.InCiteCSLStandard); ButtonCSLStandard.Caption = LocalisationManager.Get("INCITE/CAP/CSL_STANDARD"); ButtonCSLStandard.ToolTip = LocalisationManager.Get("INCITE/TIP/CSL_STANDARD"); ButtonCSLStandard.Click += ButtonCSLStandard_Click; ButtonCSLDownload.Icon = Icons.GetAppIcon(Icons.InCiteCSLDownload); ButtonCSLDownload.Caption = LocalisationManager.Get("INCITE/CAP/CSL_BROWSE"); ButtonCSLDownload.ToolTip = LocalisationManager.Get("INCITE/TIP/CSL_BROWSE"); ButtonCSLDownload.Click += ButtonCSLDownload_Click; ButtonEditCSL_Web.Click += ButtonEditCSL_Web_Click; ButtonEditCSL_Web.Icon = Icons.GetAppIcon(Icons.InCiteEditCSL); ButtonEditCSL_Web.Caption = "Open Web CSL Editor (Beginner)"; ButtonEditCSL_Web.ToolTip = LocalisationManager.Get("INCITE/TIP/CSL_EDIT"); ButtonEditCSL_Internal.Click += ButtonEditCSL_Internal_Click; ButtonEditCSL_Internal.Icon = Icons.GetAppIcon(Icons.InCiteEditCSL); ButtonEditCSL_Internal.Caption = "Open Qiqqa CSL Editor (Advanced)"; ButtonEditCSL_Internal.ToolTip = LocalisationManager.Get("INCITE/TIP/CSL_EDIT"); ButtonTools.AttachPopup(ButtonToolsPopup); ButtonTools.Icon = Icons.GetAppIcon(Icons.ModuleConfiguration); if (!ADVANCED_MENUS) { ButtonTools.Caption = LocalisationManager.Get("INCITE/CAP/TOOLS"); } ButtonFindUsedReferences.Icon = Icons.GetAppIcon(Icons.InCiteFindUsedReferences); ButtonFindUsedReferences.Caption = LocalisationManager.Get("INCITE/CAP/CSL_FIND"); ButtonFindUsedReferences.ToolTip = LocalisationManager.Get("INCITE/TIP/CSL_FIND"); ButtonFindUsedReferences.Click += ButtonFindUsedReferences_Click; ButtonAddCSLStats.Icon = Icons.GetAppIcon(Icons.InCiteAddCSLStats); ButtonAddCSLStats.Caption = LocalisationManager.Get("INCITE/CAP/ADD_CSL_STATS"); ButtonAddCSLStats.ToolTip = LocalisationManager.Get("INCITE/TIP/ADD_CSL_STATS"); ButtonAddCSLStats.Click += ButtonAddCSLStats_Click; ButtonUseAbbreviations.Icon = Icons.GetAppIcon(Icons.InCiteAbbreviations); ButtonUseAbbreviations.Caption = LocalisationManager.Get("INCITE/CAP/ABBREVIATIONS"); ButtonUseAbbreviations.ToolTip = LocalisationManager.Get("INCITE/TIP/ABBREVIATIONS"); ButtonUseAbbreviations.DataContext = ConfigurationManager.Instance.ConfigurationRecord_Bindable; ButtonCustomAbbreviationsFilename.Icon = Icons.GetAppIcon(Icons.InCiteAbbreviations); ButtonCustomAbbreviationsFilename.Caption = LocalisationManager.Get("INCITE/CAP/CUSTOM_ABBREVIATIONS_FILENAME"); ButtonCustomAbbreviationsFilename.ToolTip = LocalisationManager.Get("INCITE/TIP/CUSTOM_ABBREVIATIONS_FILENAME"); ButtonCustomAbbreviationsFilename.Click += ButtonCustomAbbreviationsFilename_Click; ButtonToggleWatcher.Icon = Icons.GetAppIcon(Icons.InCitePause); ButtonToggleWatcher.Caption = LocalisationManager.Get("INCITE/CAP/PAUSE"); ButtonToggleWatcher.ToolTip = LocalisationManager.Get("INCITE/TIP/PAUSE"); ButtonToggleWatcher.Click += ButtonToggleWatcher_Click; ButtonLaunchWord.Icon = Icons.GetAppIcon(Icons.ExportWord2007); ButtonLaunchWord.Caption = LocalisationManager.Get("INCITE/CAP/LAUNCHWORD"); ButtonLaunchWord.ToolTip = LocalisationManager.Get("INCITE/TIP/LAUNCHWORD"); ButtonLaunchWord.Click += ButtonLaunchWord_Click; ButtonInCitePopup.Icon = Icons.GetAppIcon(Icons.InCiteToolbarOpenPopup); ButtonInCitePopup.Caption = LocalisationManager.Get("INCITE/CAP/INCITE_POPUP"); ButtonInCitePopup.ToolTip = LocalisationManager.Get("INCITE/TIP/INCITE_POPUP"); ButtonInCitePopup.Click += ButtonInCitePopup_Click; ObjCitationClusterEditorControl.CitationClusterChanged += ObjCitationClusterEditorControl_CitationClusterChanged; ObjCitationClusterEditorControl.CitationClusterOpenPDFByReferenceKey += ObjCitationClusterEditorControl_CitationClusterOpenPDFByReferenceKey; Webcasts.FormatWebcastButton(ButtonWebcast, Webcasts.INCITE); if (!ADVANCED_MENUS) { ButtonWebcast.Caption = "Tutorial\n"; } ButtonConnection.Icon = Icons.GetAppIcon(Icons.InCiteConnection); ButtonConnection.CaptionDock = Dock.Right; LblTextStyleFilename.Visibility = ADVANCED_MENUS ? Visibility.Collapsed : Visibility.Visible; TextStyleFilename.FontSize = ThemeColours.HEADER_FONT_SIZE; TextStyleFilename.FontFamily = ThemeTextStyles.FontFamily_Header; TextStyleFilename.TextTrimming = TextTrimming.CharacterEllipsis; TextStyleFilename.DataContext = ConfigurationManager.Instance.ConfigurationRecord_Bindable; TextStyleFilename.PreviewMouseDown += TextStyleFilename_PreviewMouseDown; TextStyleFilename.Cursor = Cursors.Hand; TextStyleFilename.ToolTip = "Click to choose a citation formatting style file saved somewhere on your computer."; LblTextLibraryForCitations.Visibility = ADVANCED_MENUS ? Visibility.Collapsed : Visibility.Visible; TextLibraryForCitations.FontSize = ThemeColours.HEADER_FONT_SIZE; TextLibraryForCitations.FontFamily = ThemeTextStyles.FontFamily_Header; TextLibraryForCitations.TextWrapping = TextWrapping.Wrap; TextLibraryForCitations.PreviewMouseDown += TextLibraryForCitations_PreviewMouseDown; TextLibraryForCitations.ToolTip = "Click to choose a library to search for citations."; TextLibraryForCitations.Cursor = Cursors.Hand; MatchPreviousWebLibraryDetail(); ObjHyperlinkFixWordConnection.Click += ObjHyperlinkFixWordConnection_Click; WordConnector.Instance.ContextChanged += word_connector_ContextChanged; WordConnector.Instance.CitationClusterChanged += word_connector_CitationClusterChanged; // Initialise the buttons WordConnector.Instance.ReissueContextChanged(); }
public PDFReadingControl(PDFDocument pdf_document) { InitializeComponent(); pdf_renderer_control = new PDFRendererControl(pdf_document, true); pdf_renderer_control.OperationModeChanged += pdf_renderer_control_OperationModeChanged; pdf_renderer_control.ZoomTypeChanged += pdf_renderer_control_ZoomTypeChanged; pdf_renderer_control.SelectedPageChanged += pdf_renderer_control_SelectedPageChanged; pdf_renderer_control_stats = new PDFRendererControlStats(pdf_renderer_control, pdf_document); Utilities.GUI.Animation.Animations.EnableHoverFade(ObjToolbarGrid); // Add the renderer control to our grid PDFRendererControlArea.Children.Add(pdf_renderer_control); HighlightCanvasToolbar.PDFRendererControl = pdf_renderer_control; InkCanvasToolbar.PDFRendererControl = pdf_renderer_control; TextCanvasToolbar.PDFRendererControl = pdf_renderer_control; KeyUp += PDFReadingControl_KeyUp; ButtonHand.Icon = Icons.GetAppIcon(Icons.Hand); ButtonHand.ToolTip = LocalisationManager.Get("PDF/TIP/MOVE_PAGE"); ButtonHand.Click += ButtonHand_Click; ButtonTextSentenceSelect.Icon = Icons.GetAppIcon(Icons.TextSentenceSelect); ButtonTextSentenceSelect.ToolTip = LocalisationManager.Get("PDF/TIP/SELECT_TEXT"); ButtonTextSentenceSelect.Click += ButtonTextSentenceSelect_Click; ButtonAnnotation.Icon = Icons.GetAppIcon(Icons.Annotation); ButtonAnnotation.ToolTip = LocalisationManager.Get("PDF/TIP/ADD_ANNOTATION"); ButtonAnnotation.Click += ButtonAnnotation_Click; ButtonHighlighter.Icon = Icons.GetAppIcon(Icons.Highlighter); ButtonHighlighter.ToolTip = LocalisationManager.Get("PDF/TIP/ADD_HIGHLIGHT"); ButtonHighlighter.Click += ButtonHighlighter_Click; ButtonCamera.Icon = Icons.GetAppIcon(Icons.Camera); ButtonCamera.ToolTip = LocalisationManager.Get("PDF/TIP/SNAPSHOT"); ButtonCamera.Click += ButtonCamera_Click; ButtonInk.Icon = Icons.GetAppIcon(Icons.Ink); ButtonInk.ToolTip = LocalisationManager.Get("PDF/TIP/ADD_INK"); ButtonInk.Click += ButtonInk_Click; ButtonExplore.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonExplore.AttachPopup(ButtonExplorePopup); ButtonExplore.Icon = Icons.GetAppIcon(Icons.Explore); ButtonExplore.ToolTip = LocalisationManager.Get("PDF/TIP/EXPLORE"); ButtonExpedition.Icon = Icons.GetAppIcon(Icons.ModuleExpedition); ButtonExpedition.Caption = LocalisationManager.Get("PDF/TIP/EXPEDITION"); ButtonExpedition.Click += ButtonExpedition_Click; ButtonExploreInBrainstorm.Icon = Icons.GetAppIcon(Icons.ModuleBrainstorm); ButtonExploreInBrainstorm.Caption = LocalisationManager.Get("PDF/TIP/BRAINSTORM"); ButtonExploreInBrainstorm.Click += ButtonExploreInBrainstorm_Click; ButtonInCite.AttachPopup(ButtonInCitePopup); ButtonInCite.Icon = Icons.GetAppIcon(Icons.ModuleInCite); ButtonInCite.ToolTip = LocalisationManager.Get("PDF/TIP/INCITE"); ButtonInCite_Word.Icon = Icons.GetAppIcon(Icons.InCiteNewCitation); ButtonInCite_Word.Caption = LocalisationManager.Get("PDF/CAP/CITE_WORD"); ButtonInCite_Word.Click += ButtonInCite_Word_Click; ButtonInCite_WordSeparate.Icon = Icons.GetAppIcon(Icons.InCiteNewCitation); ButtonInCite_WordSeparate.Caption = LocalisationManager.Get("PDF/CAP/CITE_WORD_SEPARATE"); ButtonInCite_WordSeparate.Click += ButtonInCite_WordSeparate_Click; ButtonInCite_Snippet.Icon = Icons.GetAppIcon(Icons.InCiteCitationSnippet); ButtonInCite_Snippet.Caption = LocalisationManager.Get("PDF/CAP/CITE_SNIPPET"); ButtonInCite_Snippet.Click += ButtonInCite_Snippet_Click; ButtonInCite_BibTeXKey.Icon = Icons.GetAppIcon(Icons.ExportBibTex); ButtonInCite_BibTeXKey.Caption = LocalisationManager.Get("PDF/CAP/CITE_BIBTEX"); ButtonInCite_BibTeXKey.Click += ButtonInCite_BibTeXKey_Click; ButtonFullScreen.Icon = Icons.GetAppIcon(Icons.DocumentFullScreen); ButtonFullScreen.ToolTip = LocalisationManager.Get("PDF/TIP/FULL_SCREEN"); ButtonFullScreen.Click += ButtonFullScreen_Click; ButtonZoom.AttachPopup(ButtonZoomPopup); ButtonZoom.Icon = Icons.GetAppIcon(Icons.ZoomIn); ButtonZoom.ToolTip = LocalisationManager.Get("PDF/TIP/ZOOM"); Button1Up.Icon = Icons.GetAppIcon(Icons.Page1Up); Button1Up.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_1"); Button1Up.Click += Button1Up_Click; Button2Up.Icon = Icons.GetAppIcon(Icons.Page2Up); Button2Up.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_2"); Button2Up.Click += Button2Up_Click; ButtonNUp.Icon = Icons.GetAppIcon(Icons.PageNUp); ButtonNUp.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_N"); ButtonNUp.Click += ButtonNUp_Click; ButtonWholeUp.Icon = Icons.GetAppIcon(Icons.PageWholeUp); ButtonWholeUp.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_WHOLE"); ButtonWholeUp.Click += ButtonWholeUp_Click; ButtonRotate.Icon = Icons.GetAppIcon(Icons.PageRotate); ButtonRotate.Caption = LocalisationManager.Get("PDF/TIP/ROTATE"); ButtonRotate.Click += ButtonRotate_Click; ButtonRotateAll.Icon = Icons.GetAppIcon(Icons.PageRotate); ButtonRotateAll.Caption = LocalisationManager.Get("PDF/TIP/ROTATE_ALL"); ButtonRotateAll.Click += ButtonRotateAll_Click; ButtonZoomIn.Icon = Icons.GetAppIcon(Icons.ZoomIn); ButtonZoomIn.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_IN"); ButtonZoomIn.Click += ButtonZoomIn_Click; ButtonZoomOut.Icon = Icons.GetAppIcon(Icons.ZoomOut); ButtonZoomOut.Caption = LocalisationManager.Get("PDF/TIP/ZOOM_OUT"); ButtonZoomOut.Click += ButtonZoomOut_Click; ButtonMisc.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonMisc.AttachPopup(ButtonMiscPopup); ButtonMisc.Icon = Icons.GetAppIcon(Icons.DocumentMisc); ButtonMisc.ToolTip = LocalisationManager.Get("PDF/TIP/MISC"); ButtonDocumentSave.Icon = Icons.GetAppIcon(Icons.DocumentSave); ButtonDocumentSave.Caption = LocalisationManager.Get("PDF/TIP/SAVE_COPY"); ButtonDocumentSave.Click += ButtonDocumentSave_Click; ButtonPrint.Icon = Icons.GetAppIcon(Icons.Printer); ButtonPrint.Caption = LocalisationManager.Get("PDF/TIP/PRINT"); ButtonPrint.Click += ButtonPrint_Click; ButtonOpenLibrary.Icon = Icons.GetAppIcon(Icons.ModuleDocumentLibrary); ButtonOpenLibrary.Caption = LocalisationManager.Get("PDF/TIP/OPEN_PARENT_LIBRARY"); ButtonOpenLibrary.Click += ButtonOpenLibrary_Click; ButtonExportToText.Icon = Icons.GetAppIcon(Icons.ExportToText); ButtonExportToText.Caption = LocalisationManager.Get("PDF/TIP/CONVERT_TO_TEXT"); ButtonExportToText.Click += ButtonExportToText_Click; ButtonReadOutLoud.Icon = Icons.GetAppIcon(Icons.ReadOutLoud); ButtonReadOutLoud.Caption = LocalisationManager.Get("PDF/TIP/READ_ALOUD"); ButtonReadOutLoud.Click += ButtonReadOutLoud_Click; ButtonSpeedRead.Icon = Icons.GetAppIcon(Icons.SpeedRead); ButtonSpeedRead.Caption = LocalisationManager.Get("PDF/TIP/SPEED_READ"); ButtonSpeedRead.Click += ButtonSpeedRead_Click; ButtonInvertColours.Icon = Icons.GetAppIcon(Icons.DocumentsInvertColours); ButtonInvertColours.Caption = LocalisationManager.Get("PDF/TIP/NEGATIVE"); ButtonInvertColours.IsChecked = false; ButtonInvertColours.Click += ButtonInvertColours_Click; ButtonMoreMenus.Icon = Icons.GetAppIcon(Icons.DocumentMisc); ButtonMoreMenus.Caption = LocalisationManager.Get("PDF/TIP/MORE_MENUS"); ButtonMoreMenus.Click += ButtonMoreMenus_Click; ButtonJumpToSection.Icon = Icons.GetAppIcon(Icons.JumpToSection); ButtonJumpToSection.ToolTip = LocalisationManager.Get("PDF/TIP/BOOKMARKS"); ButtonJumpToSection.Click += ButtonJumpToSection_Click; ButtonPreviousPage.Icon = Icons.GetAppIcon(Icons.Previous); ButtonPreviousPage.ToolTip = LocalisationManager.Get("PDF/TIP/PAGE_PREV"); ButtonPreviousPage.Click += ButtonPreviousPage_Click; ButtonNextPage.Icon = Icons.GetAppIcon(Icons.Next); ButtonNextPage.ToolTip = LocalisationManager.Get("PDF/TIP/PAGE_NEXT"); ButtonNextPage.Click += ButtonNextPage_Click; TextBoxFind.ToolTip = LocalisationManager.Get("PDF/TIP/SEARCH"); TextBoxFind.OnHardSearch += TextBoxFind_OnHardSearch; Webcasts.FormatWebcastButton(ButtonWebcast, Webcasts.PDF_VIEWER); // Make some space ToolBar.SetOverflowMode(ButtonPrint, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonInvertColours, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonCamera, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonDocumentSave, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonExportToText, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonReadOutLoud, OverflowMode.Always); ToolBar.SetOverflowMode(ButtonMoreMenus, OverflowMode.Always); // Wizard WizardDPs.SetPointOfInterest(ButtonAnnotation, "PDFReadingAnnotationButton"); ListSearchDetails.SearchSelectionChanged += ListSearchDetails_SearchSelectionChanged; ListSearchDetails.SearchClicked += ListSearchDetails_SearchSelectionChanged; TagCloud.TagClick += TagCloud_TagClick; JumpToPageNumber.Text = "" + 1; JumpToPageNumberMax.Text = " of " + pdf_renderer_control_stats.pdf_document.PDFRenderer.PageCount; JumpToPageNumber.KeyDown += JumpToPageNumber_KeyDown; JumpToPageNumber.KeyUp += JumpToPageNumber_KeyUp; JumpToPageNumber.GotFocus += JumpToPageNumber_GotFocus; string tooltip = LocalisationManager.Get("PDF/TIP/PAGE_JUMP"); JumpToPageNumberLabel.ToolTip = tooltip; JumpToPageNumber.ToolTip = tooltip; // The search results are initially hidden GridBOTTOM.Visibility = Visibility.Collapsed; // Start in hand mode pdf_renderer_control.ReconsiderOperationMode(PDFRendererControl.OperationMode.Hand); ObjHyperlinkGuestPreviewMoveOther.Click += ObjHyperlinkGuestPreviewMoveOther_Click; ObjHyperlinkGuestPreviewMoveDefault.Click += ObjHyperlinkGuestPreviewMoveDefault_Click; ObjHyperlinkGuestPreviewVanillaAttach.Click += ObjHyperlinkGuestPreviewVanillaAttach_Click; ObjReadOnlyInfoBar.Visibility = pdf_document.Library.WebLibraryDetail.IsReadOnly ? Visibility.Visible : Visibility.Collapsed; DataContext = pdf_document.Bindable; ObjDocumentMetadataControlsPanel.SelectedPageChanged += ObjDocumentMetadataControlsPanel_ObjDocumentMetadataControlsPanel_SelectedPageChanged; // Kick off a thread that populates the interesting analysis SafeThreadPool.QueueUserWorkItem(o => PDFRendererControlInterestingAnalysis.DoInterestingAnalysis(this, pdf_renderer_control, pdf_renderer_control_stats)); Loaded += PDFReadingControl_Loaded; }
public LibraryControl(WebLibraryDetail web_library_detail) { Theme.Initialize(); Logging.Debug("+LibraryControl()"); this.web_library_detail = web_library_detail; dual_tab_drag_to_library_manager = new DragToLibraryManager(web_library_detail); InitializeComponent(); ImageLibraryEmptyAddFiles.Source = Icons.GetAppIcon(Icons.LibraryEmptyAddFiles); RenderOptions.SetBitmapScalingMode(ImageLibraryEmptyAddFiles, BitmapScalingMode.HighQuality); ImageLibraryMissingBibTeX.Source = Icons.GetAppIcon(Icons.BibTexSniffer); RenderOptions.SetBitmapScalingMode(ImageLibraryMissingBibTeX, BitmapScalingMode.HighQuality); bool ADVANCED_MENUS = ConfigurationManager.Instance.ConfigurationRecord.GUI_AdvancedMenus; // Connect the dropdowns ButtonAddPDF.AttachPopup(ButtonAddPDFPopup); ButtonAddPDF.Icon = Icons.GetAppIcon(Icons.DocumentsAddToLibrary); if (!ADVANCED_MENUS) { ButtonAddPDF.Caption = LocalisationManager.Get("LIBRARY/CAP/POPUP_ADD_DOCUMENTS"); } ButtonAddPDF.ToolTip = LocalisationManager.Get("LIBRARY/TIP/POPUP_ADD_DOCUMENTS"); ButtonSync.AttachPopup(ButtonSyncPopup); ButtonSync.Icon = Icons.GetAppIcon(Icons.SyncWithCloud); if (!ADVANCED_MENUS) { ButtonSync.Caption = LocalisationManager.Get("LIBRARY/CAP/POPUP_SYNC"); } ButtonSync.ToolTip = LocalisationManager.Get("LIBRARY/TIP/POPUP_SYNC"); // Then the menus ButtonAddVanillaReference.Icon = Icons.GetAppIcon(Icons.New); ButtonAddVanillaReference.Caption = LocalisationManager.Get("LIBRARY/CAP/ADD_REFERENCE"); ButtonAddVanillaReference.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ADD_REFERENCE"); ButtonAddVanillaReference.Click += ButtonAddVanillaReference_Click; ButtonSyncMetadaWithCloud.Icon = Icons.GetAppIcon(Icons.SyncWithCloud); ButtonSyncMetadaWithCloud.Caption = LocalisationManager.Get("LIBRARY/CAP/PARTIAL_SYNC"); ButtonSyncMetadaWithCloud.ToolTip = LocalisationManager.Get("LIBRARY/TIP/PARTIAL_SYNC"); ButtonSyncMetadaWithCloud.Click += ButtonSyncMetadaWithCloud_Click; ButtonSyncAllPDFsWithCloud.Icon = Icons.GetAppIcon(Icons.SyncPDFsWithCloud); ButtonSyncAllPDFsWithCloud.Caption = LocalisationManager.Get("LIBRARY/CAP/FULL_SYNC"); ButtonSyncAllPDFsWithCloud.ToolTip = LocalisationManager.Get("LIBRARY/TIP/FULL_SYNC"); ButtonSyncAllPDFsWithCloud.Click += ButtonSyncPDFsWithCloud_Click; ButtonSyncDetails.Icon = Icons.GetAppIcon(Icons.SyncDetails); ButtonSyncDetails.Caption = LocalisationManager.Get("LIBRARY/CAP/SYNC_DETAILS"); ButtonSyncDetails.ToolTip = LocalisationManager.Get("LIBRARY/TIP/SYNC_DETAILS"); ButtonSyncDetails.Click += ButtonSyncDetails_Click; ButtonEdit.Icon = Icons.GetAppIcon(Icons.Open); ButtonEdit.Caption = LocalisationManager.Get("LIBRARY/CAP/EDIT"); ButtonEdit.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EDIT"); ButtonEdit.Click += ButtonEdit_Click; ButtonDelete.Icon = Icons.GetAppIcon(Icons.Open); ButtonDelete.Caption = LocalisationManager.Get("LIBRARY/CAP/DELETE"); ButtonDelete.ToolTip = LocalisationManager.Get("LIBRARY/TIP/DELETE"); ButtonDelete.Click += ButtonDelete_Click; ButtonAnnotationsReport.Icon = Icons.GetAppIcon(Icons.LibraryAnnotationsReport); if (!ADVANCED_MENUS) { ButtonAnnotationsReport.Caption = LocalisationManager.Get("LIBRARY/CAP/ANNOTATION_REPORT"); } ButtonAnnotationsReport.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ANNOTATION_REPORT"); ButtonAnnotationsReport.Click += ButtonAnnotationsReport_Click; WizardDPs.SetPointOfInterest(ButtonAnnotationsReport, "LibraryAnnotationReportButton"); ButtonGenerateReferences.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonGenerateReferences.Icon = Icons.GetAppIcon(Icons.LibraryGenerateReferences); if (!ADVANCED_MENUS) { ButtonGenerateReferences.Caption = LocalisationManager.Get("LIBRARY/CAP/FIND_REFERENCES"); } ButtonGenerateReferences.ToolTip = LocalisationManager.Get("LIBRARY/TIP/FIND_REFERENCES"); ButtonGenerateReferences.Click += ButtonGenerateReferences_Click; ButtonFindDuplicates.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonFindDuplicates.Icon = Icons.GetAppIcon(Icons.LibraryFindDuplicates); if (!ADVANCED_MENUS) { ButtonFindDuplicates.Caption = LocalisationManager.Get("LIBRARY/CAP/FIND_DUPLICATES"); } ButtonFindDuplicates.ToolTip = LocalisationManager.Get("LIBRARY/TIP/FIND_DUPLICATES"); ButtonFindDuplicates.Click += ButtonFindDuplicates_Click; ButtonBibTexSniffer.Icon = Icons.GetAppIcon(Icons.BibTexSniffer); if (!ADVANCED_MENUS) { ButtonBibTexSniffer.Caption = LocalisationManager.Get("LIBRARY/CAP/BIBTEX_SNIFFER"); } ButtonBibTexSniffer.ToolTip = LocalisationManager.Get("LIBRARY/TIP/BIBTEX_SNIFFER"); ButtonBibTexSniffer.Click += ButtonBibTexSniffer_Click; ButtonExplore.AttachPopup(ButtonExplorePopup); ButtonExplore.Icon = Icons.GetAppIcon(Icons.Explore); if (!ADVANCED_MENUS) { ButtonExplore.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPLORE"); } ButtonExplore.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPLORE"); ButtonExplore.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonExpedition.Icon = Icons.GetAppIcon(Icons.ModuleExpedition); ButtonExpedition.Caption = LocalisationManager.Get("LIBRARY/TIP/EXPEDITION"); ButtonExpedition.Click += ButtonExpedition_Click; ButtonExploreInBrainstorm.Icon = Icons.GetAppIcon(Icons.ModuleBrainstorm); ButtonExploreInBrainstorm.Caption = LocalisationManager.Get("LIBRARY/TIP/BRAINSTORM"); ButtonExploreInBrainstorm.Click += ButtonExploreInBrainstorm_Click; ButtonExploreInPivot.Icon = Icons.GetAppIcon(Icons.LibraryPivot); ButtonExploreInPivot.Caption = LocalisationManager.Get("LIBRARY/TIP/PIVOT"); ButtonExploreInPivot.Click += ButtonExploreInPivot_Click; ButtonExport.AttachPopup(ButtonExportPopup); ButtonExport.Icon = Icons.GetAppIcon(Icons.LibraryExport); if (!ADVANCED_MENUS) { ButtonExport.Caption = LocalisationManager.Get("LIBRARY/CAP/POPUP_EXPORT"); } ButtonExport.ToolTip = LocalisationManager.Get("LIBRARY/TIP/POPUP_EXPORT"); ButtonExport.Visibility = ConfigurationManager.Instance.NoviceVisibility; ButtonExportLibrary.Icon = Icons.GetAppIcon(Icons.LibraryExport); ButtonExportLibrary.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_LIBRARY"); ButtonExportLibrary.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_LIBRARY"); ButtonExportLibrary.Click += ButtonExportLibrary_Click; ButtonExportBibTex.Icon = Icons.GetAppIcon(Icons.ExportBibTex); ButtonExportBibTex.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_BIBTEX"); ButtonExportBibTex.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_BIBTEX"); ButtonExportBibTex.Click += ButtonExportBibTex_Click; ButtonExportWord2007.Icon = Icons.GetAppIcon(Icons.ExportWord2007); ButtonExportWord2007.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_WORD"); ButtonExportWord2007.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_WORD"); ButtonExportWord2007.Click += ButtonExportWord2007_Click; ButtonExportCitationMatrix.Icon = Icons.GetAppIcon(Icons.ExportCitationMatrix); ButtonExportCitationMatrix.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_CITATION_MATRIX"); ButtonExportCitationMatrix.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_CITATION_MATRIX"); ButtonExportCitationMatrix.Click += ButtonExportCitationMatrix_Click; ButtonExportLinkedDocs.Icon = Icons.GetAppIcon(Icons.ExportCitationMatrix); ButtonExportLinkedDocs.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_LINKED_DOCS"); ButtonExportLinkedDocs.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_LINKED_DOCS"); ButtonExportLinkedDocs.Click += ButtonExportLinkedDocs_Click; ButtonBuildBundleLibrary.Icon = Icons.GetAppIcon(Icons.BuildBundleLibrary); ButtonBuildBundleLibrary.Caption = LocalisationManager.Get("LIBRARY/CAP/BUILD_BUNDLE_LIBRARY"); ButtonBuildBundleLibrary.ToolTip = LocalisationManager.Get("LIBRARY/TIP/BUILD_BUNDLE_LIBRARY"); ButtonBuildBundleLibrary.Click += ButtonBuildBundleLibrary_Click; ButtonExportAnnotationsCode.Icon = Icons.GetAppIcon(Icons.ExportBibTex); ButtonExportAnnotationsCode.Caption = LocalisationManager.Get("LIBRARY/CAP/EXPORT_ANNOTATIONS_CODE"); ButtonExportAnnotationsCode.ToolTip = LocalisationManager.Get("LIBRARY/TIP/EXPORT_ANNOTATIONS_CODE"); ButtonExportAnnotationsCode.Click += ButtonExportAnnotationsCode_Click; ButtonAddDocuments.Icon = Icons.GetAppIcon(Icons.DocumentsAddToLibrary); ButtonAddDocuments.Caption = LocalisationManager.Get("LIBRARY/CAP/ADD_DOCUMENTS"); ButtonAddDocuments.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ADD_DOCUMENTS"); ButtonAddDocuments.Click += ButtonAddDocuments_Click; ButtonAddDocumentsFromFolder.Icon = Icons.GetAppIcon(Icons.DocumentsAddToLibraryFromFolder); ButtonAddDocumentsFromFolder.Caption = LocalisationManager.Get("LIBRARY/CAP/ADD_FOLDER"); ButtonAddDocumentsFromFolder.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ADD_FOLDER"); ButtonAddDocumentsFromFolder.Click += ButtonAddDocumentsFromFolder_Click; ButtonAddDocumentsFromLibrary.Icon = Icons.GetAppIcon(Icons.DocumentsAddToLibraryFromLibrary); ButtonAddDocumentsFromLibrary.Caption = LocalisationManager.Get("LIBRARY/CAP/ADD_LIBRARY"); ButtonAddDocumentsFromLibrary.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ADD_LIBRARY"); ButtonAddDocumentsFromLibrary.Click += ButtonAddDocumentsFromLibrary_Click; ButtonWatchFolder.Icon = Icons.GetAppIcon(Icons.DocumentsWatchFolder); ButtonWatchFolder.Caption = LocalisationManager.Get("LIBRARY/CAP/WATCH_FOLDER"); ButtonWatchFolder.ToolTip = LocalisationManager.Get("LIBRARY/TIP/WATCH_FOLDER"); ButtonWatchFolder.Click += ButtonWatchFolder_Click; ButtonImportFromThirdParty.Icon = Icons.GetAppIcon(Icons.DocumentsImportFromThirdParty); ButtonImportFromThirdParty.Caption = LocalisationManager.Get("LIBRARY/CAP/ADD_IMPORT"); ButtonImportFromThirdParty.ToolTip = LocalisationManager.Get("LIBRARY/TIP/ADD_IMPORT"); ButtonImportFromThirdParty.Click += ButtonImportFromThirdParty_Click; ButtonAddMissingDocumentsFromSelf.Icon = Icons.GetAppIcon(Icons.DocumentsAddMissingFromSelf); ButtonAddMissingDocumentsFromSelf.Caption = "Recover unregistered PDFs in this library"; ButtonAddMissingDocumentsFromSelf.ToolTip = "This is a live library recovery/restoration operation: inspect the current library's storage and re-register all PDFs in there, which have not been registered in the library already."; ButtonAddMissingDocumentsFromSelf.Click += ButtonAddMissingDocumentsFromSelf_Click; ObjLibraryEmptyDescriptionText.Background = ThemeColours.Background_Brush_Blue_LightToDark; // Tie all our GUI objects together ObjLibraryFilterControl.library_filter_control_search = ObjLibraryFilterControl_Search; ObjLibraryFilterControl_Search.library_filter_control = ObjLibraryFilterControl; ObjLibraryFilterControl.OnFilterChanged += ObjLibraryFilterControl_OnFilterChanged; ObjLibraryFilterControl.OnFilterChanged += ObjLibraryFilterOverviewControl.OnFilterChanged; ObjLibraryFilterControl.OnFilterChanged += ObjLibraryCatalogControl.OnFilterChanged; ObjLibraryFilterControl.LibraryRef = web_library_detail; ObjLibraryFilterControl.ResetFilters(true); ObjLibraryCatalogControl.LibraryRef = web_library_detail; // Catch some keyboard commands KeyDown += LibraryControl_KeyDown; if (!ADVANCED_MENUS) { ButtonWebcast.Caption = "Tutorial\n"; } Webcasts.FormatWebcastButton(ButtonWebcast, Webcasts.LIBRARY); // IF the library is read-only? ReflectReadOnlyStatus(); Logging.Debug("-LibraryControl()"); }
public GoogleBibTexSnifferControl() { InitializeComponent(); // Search options search_options = new SearchOptions(); search_options_bindable = new AugmentedBindable <SearchOptions>(search_options); ObjSearchOptionsPanel.DataContext = search_options_bindable; search_options_bindable.PropertyChanged += search_options_bindable_PropertyChanged; // Fades of buttons Utilities.GUI.Animation.Animations.EnableHoverFade(PDFRendererControlAreaButtonPanel); Utilities.GUI.Animation.Animations.EnableHoverFade(ObjBibTeXEditButtonPanel); this.Title = "Qiqqa BibTeX Sniffer"; this.Closing += GoogleBibTexSnifferControl_Closing; this.Closed += GoogleBibTexSnifferControl_Closed; this.KeyUp += GoogleBibTexSnifferControl_KeyUp; ButtonPrev.Icon = Icons.GetAppIcon(Icons.Back); ButtonPrev.ToolTip = "Move to previous PDF."; ButtonPrev.Click += ButtonPrev_Click; ButtonNext.Icon = Icons.GetAppIcon(Icons.Forward); ButtonNext.ToolTip = "Move to next PDF. You can press the middle key (the 5 key) as a shortcut."; ButtonNext.Click += ButtonNext_Click; ButtonClear.Icon = Icons.GetAppIcon(Icons.GoogleBibTexSkipForever); ButtonClear.ToolTip = "Clear this BibTeX."; ButtonClear.Click += ButtonClear_Click; ButtonSkipForever.Icon = Icons.GetAppIcon(Icons.GoogleBibTexSkip); ButtonSkipForever.ToolTip = "This document has no BibTeX. Skip it!"; ButtonSkipForever.Click += ButtonSkipForever_Click; ButtonValidate.Icon = Icons.GetAppIcon(Icons.GoogleBibTexNext); ButtonValidate.ToolTip = "The automatic BibTeX for this document is great. Mark it as valid!"; ButtonValidate.Click += ButtonValidate_Click; ButtonConfig.Icon = Icons.GetAppIcon(Icons.DocumentMisc); ButtonConfig.ToolTip = LocalisationManager.Get("PDF/TIP/MORE_MENUS"); ButtonConfig.Click += ButtonConfig_Click; ButtonRedo.Icon = Icons.GetAppIcon(Icons.DesktopRefresh); ButtonRedo.ToolTip = "Retry detection of this PDF."; ButtonRedo.Click += ButtonRedo_Click; ButtonWizard.Icon = Icons.GetAppIcon(Icons.BibTeXSnifferWizard); ButtonWizard.ToolTip = "Toggle the BibTeX Sniffer Wizard.\nWhen this is enabled, the sniffer will automatically browse to the first item it sees in Google Scholar.\nThis saves you time because you just have to scan that the BibTeX is correct before moving onto your next paper!"; ButtonWizard.DataContext = ConfigurationManager.Instance.ConfigurationRecord_Bindable; ObjWebBrowser.GoBibTeXMode(); ObjWebBrowser.PageLoaded += ObjWebBrowser_PageLoaded; ObjWebBrowser.TabChanged += ObjWebBrowser_TabChanged; PDFRendererControlArea.ToolTip = "This is the current PDF that has no BibTeX associated with it. You can select text from the PDF to automatically search for that text."; ObjWebBrowser.ToolTip = "Use this browser to hunt for BibTeX of PubMed XML. As soon as you find some, it will automatically be associated with your PDFF."; TxtBibTeX.ToolTip = "This is the BibTeX that is currently associated with the displayed PDF.\nFeel free to edit this or replace it with a # if there is no BibTeX for this record and you do not want the Sniffer to keep prompting you for some..."; HyperlinkBibTeXLinksMissing.Click += HyperlinkBibTeXLinksMissing_Click; Webcasts.FormatWebcastButton(ButtonWebcast, Webcasts.BIBTEX_SNIFFER); // Set dimensions { this.Width = 800; this.Height = 600; // Be a little larger if possible if (SystemParameters.FullPrimaryScreenWidth > 1024) { this.Height = 1024; } if (SystemParameters.FullPrimaryScreenHeight > 1024) { this.Height = 1024; } } TxtBibTeX.TextChanged += TxtBibTeX_TextChanged; // Navigate to GS in a bid to not have the first .bib prompt for download ObjWebBrowser.ForceAdvancedMenus(); ObjWebBrowser.ForceSnifferSearchers(); ObjWebBrowser.DefaultWebSearcherKey = WebSearchers.SCHOLAR_KEY; }
public BrainstormControl() { Logging.Debug("+BrainstormControl()"); InitializeComponent(); SceneRenderingControl.SceneRenderingControl_PostConstructor(ObjBrainstormMetadata); bool ADVANCED_MENUS = ConfigurationManager.Instance.ConfigurationRecord.GUI_AdvancedMenus; if (!ADVANCED_MENUS) { ButtonNew.Caption = "New\nBrainstorm"; } ButtonNew.Icon = Icons.GetAppIcon(Icons.New); ButtonNew.ToolTip = "Create a new brainstorm"; ButtonNew.Click += ButtonNew_Click; if (!ADVANCED_MENUS) { ButtonOpen.Caption = "Open\nBrainstorm"; } ButtonOpen.Icon = Icons.GetAppIcon(Icons.Open); ButtonOpen.ToolTip = "Open an existing brainstorm"; ButtonOpen.Click += ButtonOpen_Click; if (!ADVANCED_MENUS) { ButtonSave.Caption = "Save\nBrainstorm"; } ButtonSave.Icon = Icons.GetAppIcon(Icons.Save); ButtonSave.ToolTip = "Save this brainstorm"; ButtonSave.Click += ButtonSave_Click; if (!ADVANCED_MENUS) { ButtonSaveAs.Caption = "Save As\nBrainstorm"; } ButtonSaveAs.Icon = Icons.GetAppIcon(Icons.SaveAs); ButtonSaveAs.ToolTip = "Save this brainstorm as another name"; ButtonSaveAs.Click += ButtonSaveAs_Click; TextBoxFind.ToolTip = "Enter your search words here and press <ENTER> to search this brainstorm"; TextBoxFind.OnHardSearch += TextBoxFind_OnHardSearch; if (!ADVANCED_MENUS) { ButtonPrint.Caption = "Print"; } ButtonPrint.Icon = Icons.GetAppIcon(Icons.Printer); ButtonPrint.ToolTip = "Print this brainstorm"; ButtonPrint.Click += ButtonPrint_Click; if (!ADVANCED_MENUS) { ButtonZoomIn.Caption = "Zoom\nIn"; } ButtonZoomIn.Icon = Icons.GetAppIcon(Icons.ZoomIn); ButtonZoomIn.ToolTip = "Zoom in"; ButtonZoomIn.Click += ButtonZoomIn_Click; if (!ADVANCED_MENUS) { ButtonZoomOut.Caption = "Zoom\nOut"; } ButtonZoomOut.Icon = Icons.GetAppIcon(Icons.ZoomOut); ButtonZoomOut.ToolTip = "Zoom out"; ButtonZoomOut.Click += ButtonZoomOut_Click; if (!ADVANCED_MENUS) { ButtonHelp.Caption = "Toggle\nHelp"; } ButtonHelp.Icon = Icons.GetAppIcon(Icons.Help); ButtonHelp.ToolTip = "Toggle help"; ButtonHelp.Click += ButtonHelp_Click; if (!ADVANCED_MENUS) { ButtonHand.Caption = "Move\n& Pan"; } ButtonHand.Icon = Icons.GetAppIcon(Icons.Hand); ButtonHand.ToolTip = "Move around brainstorm"; ButtonHand.Click += ButtonNextClickMode_Click; if (!ADVANCED_MENUS) { ButtonAddText.Caption = "Add\nNode"; } ButtonAddText.Icon = Icons.GetAppIcon(Icons.BrainstormAddText); ButtonAddText.ToolTip = "Add a text node"; ButtonAddText.Click += ButtonNextClickMode_Click; if (!ADVANCED_MENUS) { ButtonAddConnector.Caption = "Add\nConnector"; } ButtonAddConnector.Icon = Icons.GetAppIcon(Icons.BrainstormAddConnector); ButtonAddConnector.ToolTip = "Connect two nodes in this brainstorm"; ButtonAddConnector.Click += ButtonAddConnector_Click; if (!ADVANCED_MENUS) { ButtonAddImage.Caption = "Add\nImage"; } ButtonAddImage.Icon = Icons.GetAppIcon(Icons.BrainstormAddImage); ButtonAddImage.ToolTip = "Add an image node"; ButtonAddImage.Click += ButtonNextClickMode_Click; if (!ADVANCED_MENUS) { ButtonAutoArrange.Caption = "Auto\nArrange"; } ButtonAutoArrange.Icon = Icons.GetAppIcon(Icons.BrainstormAutoArrange); ButtonAutoArrange.ToolTip = "Automatically arrange your brainstorm."; ButtonAutoArrange.Click += ButtonAutoArrange_Click; RadioNodeAdditionMode_Connect.Click += RadioNodeAdditionMode_Click; RadioNodeAdditionMode_Create.Click += RadioNodeAdditionMode_Click; { string tooltip = "When exploring your library, you can choose either to:\n\treuse nodes that are already on your brainstorm (to see existing relationships); or to\n\tcreate duplicates (to explore your library deeply without getting too cluttered)."; RadioNodeAdditionMode_Connect.ToolTip = tooltip; RadioNodeAdditionMode_Create.ToolTip = tooltip; } Webcasts.FormatWebcastButton(ButtonWebcast_Themes, Webcasts.BRAINSTORM_THEMES); if (!ADVANCED_MENUS) { ButtonWebcast_Themes.Caption = "Tutorial 1\n"; } Webcasts.FormatWebcastButton(ButtonWebcast_Intro, Webcasts.BRAINSTORM); if (!ADVANCED_MENUS) { ButtonWebcast_Intro.Caption = "Tutorial 2\n"; } // The tabs in the editor area DualTabControlArea.Children.Clear(); DualTabControlArea.AddContent("Edit", "Edit", null, false, false, ObjStackEditor); DualTabControlArea.AddContent("Help", "Help", null, false, false, ObjBrainstormControlHelpWhenEmpty); DualTabControlArea.AddContent("Info", "Info", null, false, false, ObjBrainstormMetadata); DualTabControlArea.MakeActive("Help"); LoadEditorFrameworkElement(ObjStackEditorHelpWhenEmpty); // Listen for node changes SceneRenderingControl.SelectedNodeControlChanged += ObjSceneRenderingControl_SelectedNodeControlChanged; Logging.Debug("-BrainstormControl()"); }