/* * Greenshot - a free and open source screenshot tool * Copyright (C) 2007-2016 Thomas Braun, Jens Klingen, Robin Krom * * For more information see: http://getgreenshot.org/ * The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 1 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ namespace Greenshot.Interop.Office { // See http://msdn.microsoft.com/de-de/library/microsoft.office.interop.word.applicationclass_members%28v=Office.11%29.aspx [ComProgId("Word.Application")] public interface IWordApplication : ICommon { IWordDocument ActiveDocument { get; } ISelection Selection { get; } IDocuments Documents { get; } bool Visible { get; set; } void Activate(); string Version { get; } } // See: http://msdn.microsoft.com/de-de/library/microsoft.office.interop.word.documents_members(v=office.11).aspx public interface IDocuments : ICommon, ICollection { IWordDocument Add(ref object Template, ref object NewTemplate, ref object DocumentType, ref object Visible); IWordDocument item(int index); } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.document%28v=office.14%29.aspx /// public interface IWordDocument : ICommon { void Activate(); IWordApplication Application { get; } IWordWindow ActiveWindow { get; } bool ReadOnly { get; } IHyperlinks Hyperlinks { get; } // Only 2007 and later! bool Final { get; set; } } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.window_members.aspx /// public interface IWordWindow : ICommon { IPane ActivePane { get; } void Activate(); string Caption { get; } /// /// Returns an Integer (int in C#) that indicates the window handle of the specified window /// int Hwnd { get; } } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.pane_members.aspx /// public interface IPane : ICommon { IWordView View { get; } } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.view_members.aspx /// public interface IWordView : ICommon { IZoom Zoom { get; } } // See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.zoom_members.aspx public interface IZoom : ICommon { int Percentage { get; set; } } /// /// See: http://msdn.microsoft.com/de-de/library/microsoft.office.interop.word.selection_members(v=office.11).aspx /// public interface ISelection : ICommon { IInlineShapes InlineShapes { get; } void InsertAfter(string text); int MoveDown(object Unit, object Count, object Extend); } /// /// See: http://msdn.microsoft.com/en-us/library/ms263866%28v=office.14%29.aspx /// public interface IInlineShapes : ICommon { IInlineShape AddPicture(string FileName, object LinkToFile, object SaveWithDocument, object Range); } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.inlineshape_members%28v=office.14%29.aspx /// public interface IInlineShape : ICommon { IHyperlink Hyperlink { get; } MsoTriState LockAspectRatio { get; set; } } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.hyperlink_members%28v=office.14%29.aspx /// public interface IHyperlink : ICommon { string Address { get; set; } } /// /// See: http://msdn.microsoft.com/en-us/library/microsoft.office.interop.word.hyperlinks%28v=office.14%29.aspx /// public interface IHyperlinks : ICommon, ICollection { IHyperlink Add(object Anchor, object Address, object SubAddress, object ScreenTip, object TextToDisplay, object Target); } }