mirror of
https://github.com/greenshot/greenshot
synced 2025-07-14 00:53:51 -07:00
spelling fixes
This commit is contained in:
parent
3c8c0e89c6
commit
53b17d4c4d
8 changed files with 24 additions and 24 deletions
|
@ -25,7 +25,7 @@ using GreenshotPlugin.Controls;
|
||||||
namespace Greenshot.Controls {
|
namespace Greenshot.Controls {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// A simple ToolStripDropDownButton implementing INotifyPropertyChanged for data binding.
|
/// A simple ToolStripDropDownButton implementing INotifyPropertyChanged for data binding.
|
||||||
/// Also, when a DropDownItem is selected, the DropDownButton adops its Tag and Image.
|
/// Also, when a DropDownItem is selected, the DropDownButton adopts its Tag and Image.
|
||||||
/// The selected tag can be accessed via SelectedTag property.
|
/// The selected tag can be accessed via SelectedTag property.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class BindableToolStripDropDownButton : ToolStripDropDownButton, INotifyPropertyChanged, IGreenshotLanguageBindable {
|
public class BindableToolStripDropDownButton : ToolStripDropDownButton, INotifyPropertyChanged, IGreenshotLanguageBindable {
|
||||||
|
|
|
@ -119,7 +119,7 @@ namespace Greenshot.Destinations {
|
||||||
fullPath = ImageOutput.SaveWithDialog(surface, captureDetails);
|
fullPath = ImageOutput.SaveWithDialog(surface, captureDetails);
|
||||||
outputMade = (fullPath != null);
|
outputMade = (fullPath != null);
|
||||||
}
|
}
|
||||||
// Don't overwite filename if no output is made
|
// Don't overwrite filename if no output is made
|
||||||
if (outputMade) {
|
if (outputMade) {
|
||||||
exportInformation.ExportMade = outputMade;
|
exportInformation.ExportMade = outputMade;
|
||||||
exportInformation.Filepath = fullPath;
|
exportInformation.Filepath = fullPath;
|
||||||
|
|
|
@ -225,7 +225,7 @@ namespace Greenshot.Drawing {
|
||||||
private Rectangle _boundsBeforeResize = Rectangle.Empty;
|
private Rectangle _boundsBeforeResize = Rectangle.Empty;
|
||||||
|
|
||||||
[NonSerialized]
|
[NonSerialized]
|
||||||
// "workbench" rectangle - used for calculatoing bounds during resizing (to be applied to this DrawableContainer afterwards)
|
// "workbench" rectangle - used for calculating bounds during resizing (to be applied to this DrawableContainer afterwards)
|
||||||
private RectangleF _boundsAfterResize = RectangleF.Empty;
|
private RectangleF _boundsAfterResize = RectangleF.Empty;
|
||||||
|
|
||||||
public Rectangle Bounds {
|
public Rectangle Bounds {
|
||||||
|
|
|
@ -46,7 +46,7 @@ namespace Greenshot.Drawing.Fields {
|
||||||
remove{ fieldChanged -= value; }
|
remove{ fieldChanged -= value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
// we keep to Coolections of our fields, dictionary for quick access, list for serialization
|
// we keep two Collections of our fields, dictionary for quick access, list for serialization
|
||||||
// this allows us to use default serialization
|
// this allows us to use default serialization
|
||||||
[NonSerialized]
|
[NonSerialized]
|
||||||
private Dictionary<FieldType, Field> fieldsByType = new Dictionary<FieldType, Field>();
|
private Dictionary<FieldType, Field> fieldsByType = new Dictionary<FieldType, Field>();
|
||||||
|
|
|
@ -67,7 +67,7 @@ namespace Greenshot.Drawing.Fields.Binding {
|
||||||
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
||||||
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
||||||
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
||||||
/// <param name="converter">taking care of converting the synchronzied value to the correct target format and back</param>
|
/// <param name="converter">taking care of converting the synchronized value to the correct target format and back</param>
|
||||||
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingConverter converter) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName) {
|
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingConverter converter) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName) {
|
||||||
this.converter = converter;
|
this.converter = converter;
|
||||||
}
|
}
|
||||||
|
@ -80,7 +80,7 @@ namespace Greenshot.Drawing.Fields.Binding {
|
||||||
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
||||||
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
||||||
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
||||||
/// <param name="validator">validator to intercept synchronisation if the value does not match certain criteria</param>
|
/// <param name="validator">validator to intercept synchronization if the value does not match certain criteria</param>
|
||||||
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingValidator validator) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName) {
|
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingValidator validator) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName) {
|
||||||
this.validator = validator;
|
this.validator = validator;
|
||||||
}
|
}
|
||||||
|
@ -93,8 +93,8 @@ namespace Greenshot.Drawing.Fields.Binding {
|
||||||
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
/// <param name="controlPropertyName">Property of 1st object to bind</param>
|
||||||
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
/// <param name="fieldObject">Object containing 2nd property to bind</param>
|
||||||
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
/// <param name="fieldPropertyName">Property of 2nd object to bind</param>
|
||||||
/// <param name="converter">taking care of converting the synchronzied value to the correct target format and back</param>
|
/// <param name="converter">taking care of converting the synchronized value to the correct target format and back</param>
|
||||||
/// <param name="validator">validator to intercept synchronisation if the value does not match certain criteria</param>
|
/// <param name="validator">validator to intercept synchronization if the value does not match certain criteria</param>
|
||||||
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingConverter converter, IBindingValidator validator) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName, converter) {
|
public BidirectionalBinding(INotifyPropertyChanged controlObject, string controlPropertyName, INotifyPropertyChanged fieldObject, string fieldPropertyName, IBindingConverter converter, IBindingValidator validator) : this(controlObject, controlPropertyName, fieldObject, fieldPropertyName, converter) {
|
||||||
this.validator = validator;
|
this.validator = validator;
|
||||||
}
|
}
|
||||||
|
|
|
@ -109,7 +109,7 @@ namespace Greenshot {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This is a method to popululate the ComboBox
|
/// This is a method to populate the ComboBox
|
||||||
/// with the items from the enumeration
|
/// with the items from the enumeration
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="comboBox">ComboBox to populate</param>
|
/// <param name="comboBox">ComboBox to populate</param>
|
||||||
|
|
|
@ -176,7 +176,7 @@ namespace GreenshotPlugin.Core {
|
||||||
|
|
||||||
static WindowDetails() {
|
static WindowDetails() {
|
||||||
try {
|
try {
|
||||||
// Only try to instanciate when Windows 8 or later.
|
// Only try to instantiate when Windows 8 or later.
|
||||||
if (Environment.OSVersion.Version.Major >= 6 && Environment.OSVersion.Version.Minor >= 2) {
|
if (Environment.OSVersion.Version.Major >= 6 && Environment.OSVersion.Version.Minor >= 2) {
|
||||||
appVisibility = COMWrapper.CreateInstance<IAppVisibility>();
|
appVisibility = COMWrapper.CreateInstance<IAppVisibility>();
|
||||||
}
|
}
|
||||||
|
@ -413,7 +413,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Retrieve the child with mathing classname
|
/// Retrieve the child with matching classname
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public WindowDetails GetChild(string childClassname) {
|
public WindowDetails GetChild(string childClassname) {
|
||||||
foreach(WindowDetails child in Children) {
|
foreach(WindowDetails child in Children) {
|
||||||
|
@ -425,7 +425,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Retrieve the children with mathing classname
|
/// Retrieve the children with matching classname
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public IEnumerable<WindowDetails> GetChilden(string childClassname) {
|
public IEnumerable<WindowDetails> GetChilden(string childClassname) {
|
||||||
foreach (WindowDetails child in Children) {
|
foreach (WindowDetails child in Children) {
|
||||||
|
@ -499,7 +499,7 @@ namespace GreenshotPlugin.Core {
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="titlePattern">The regexp to look for in the title</param>
|
/// <param name="titlePattern">The regexp to look for in the title</param>
|
||||||
/// <param name="classnamePattern">The regexp to look for in the classname</param>
|
/// <param name="classnamePattern">The regexp to look for in the classname</param>
|
||||||
/// <returns>List<WindowDetails> with all the found windows, or an emptry list</returns>
|
/// <returns>List<WindowDetails> with all the found windows, or an empty list</returns>
|
||||||
public List<WindowDetails> FindChildren(string titlePattern, string classnamePattern) {
|
public List<WindowDetails> FindChildren(string titlePattern, string classnamePattern) {
|
||||||
return FindWindow(Children, titlePattern, classnamePattern);
|
return FindWindow(Children, titlePattern, classnamePattern);
|
||||||
}
|
}
|
||||||
|
@ -627,7 +627,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets/Sets whether the window is iconic (mimimised) or not.
|
/// Gets/Sets whether the window is iconic (mimimized) or not.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool Iconic {
|
public bool Iconic {
|
||||||
get {
|
get {
|
||||||
|
@ -705,7 +705,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Is only partly on the screen, when this happens the app is allways visible!
|
// Is only partly on the screen, when this happens the app is always visible!
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -984,7 +984,7 @@ namespace GreenshotPlugin.Core {
|
||||||
// Correct capture size for maximized window by offsetting the X,Y with the border size
|
// Correct capture size for maximized window by offsetting the X,Y with the border size
|
||||||
captureRectangle.X += borderSize.Width;
|
captureRectangle.X += borderSize.Width;
|
||||||
captureRectangle.Y += borderSize.Height;
|
captureRectangle.Y += borderSize.Height;
|
||||||
// and subtrackting the border from the size (2 times, as we move right/down for the capture without resizing)
|
// and subtracting the border from the size (2 times, as we move right/down for the capture without resizing)
|
||||||
captureRectangle.Width -= 2 * borderSize.Width;
|
captureRectangle.Width -= 2 * borderSize.Width;
|
||||||
captureRectangle.Height -= 2 * borderSize.Height;
|
captureRectangle.Height -= 2 * borderSize.Height;
|
||||||
} else if (autoMode) {
|
} else if (autoMode) {
|
||||||
|
@ -1035,7 +1035,7 @@ namespace GreenshotPlugin.Core {
|
||||||
// Make sure the application window is active, so the colors & buttons are right
|
// Make sure the application window is active, so the colors & buttons are right
|
||||||
ToForeground();
|
ToForeground();
|
||||||
}
|
}
|
||||||
// Make sure all changes are processed and visisble
|
// Make sure all changes are processed and visible
|
||||||
Application.DoEvents();
|
Application.DoEvents();
|
||||||
using (Bitmap blackBitmap = WindowCapture.CaptureRectangle(captureRectangle)) {
|
using (Bitmap blackBitmap = WindowCapture.CaptureRectangle(captureRectangle)) {
|
||||||
capturedBitmap = ApplyTransparency(blackBitmap, whiteBitmap);
|
capturedBitmap = ApplyTransparency(blackBitmap, whiteBitmap);
|
||||||
|
@ -1043,7 +1043,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
LOG.Debug("Exception: ", e);
|
LOG.Debug("Exception: ", e);
|
||||||
// Some problem occured, cleanup and make a normal capture
|
// Some problem occurred, cleanup and make a normal capture
|
||||||
if (capturedBitmap != null) {
|
if (capturedBitmap != null) {
|
||||||
capturedBitmap.Dispose();
|
capturedBitmap.Dispose();
|
||||||
capturedBitmap = null;
|
capturedBitmap = null;
|
||||||
|
@ -1067,7 +1067,7 @@ namespace GreenshotPlugin.Core {
|
||||||
// Make sure the application window is active, so the colors & buttons are right
|
// Make sure the application window is active, so the colors & buttons are right
|
||||||
ToForeground();
|
ToForeground();
|
||||||
}
|
}
|
||||||
// Make sure all changes are processed and visisble
|
// Make sure all changes are processed and visible
|
||||||
Application.DoEvents();
|
Application.DoEvents();
|
||||||
// Capture from the screen
|
// Capture from the screen
|
||||||
capturedBitmap = WindowCapture.CaptureRectangle(captureRectangle);
|
capturedBitmap = WindowCapture.CaptureRectangle(captureRectangle);
|
||||||
|
@ -1135,7 +1135,7 @@ namespace GreenshotPlugin.Core {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Apply transparency by comparing a transparent capture with a black and white background
|
/// Apply transparency by comparing a transparent capture with a black and white background
|
||||||
/// A "Math.min" makes sure there is no overflow, but this could cause the picture to have shifted colors.
|
/// A "Math.min" makes sure there is no overflow, but this could cause the picture to have shifted colors.
|
||||||
/// The pictures should have been taken without differency, exect for the colors.
|
/// The pictures should have been taken without differency, except for the colors.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="blackBitmap">Bitmap with the black image</param>
|
/// <param name="blackBitmap">Bitmap with the black image</param>
|
||||||
/// <param name="whiteBitmap">Bitmap with the black image</param>
|
/// <param name="whiteBitmap">Bitmap with the black image</param>
|
||||||
|
@ -1350,7 +1350,7 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Return an Image representating the Window!
|
/// Return an Image representing the Window!
|
||||||
/// As GDI+ draws it, it will be without Aero borders!
|
/// As GDI+ draws it, it will be without Aero borders!
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public Image PrintWindow() {
|
public Image PrintWindow() {
|
||||||
|
@ -1451,9 +1451,9 @@ namespace GreenshotPlugin.Core {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the Destop window
|
/// Gets the Desktop window
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>WindowDetails for the destop window</returns>
|
/// <returns>WindowDetails for the desktop window</returns>
|
||||||
public static WindowDetails GetDesktopWindow() {
|
public static WindowDetails GetDesktopWindow() {
|
||||||
return new WindowDetails(User32.GetDesktopWindow());
|
return new WindowDetails(User32.GetDesktopWindow());
|
||||||
}
|
}
|
||||||
|
|
|
@ -257,7 +257,7 @@ namespace Greenshot.IniFile {
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="section">IniSection</param>
|
/// <param name="section">IniSection</param>
|
||||||
private static void FixProperties(IniSection section) {
|
private static void FixProperties(IniSection section) {
|
||||||
// Make properties unchangable
|
// Make properties unchangeable
|
||||||
if (fixedProperties != null) {
|
if (fixedProperties != null) {
|
||||||
Dictionary<string, string> fixedPropertiesForSection = null;
|
Dictionary<string, string> fixedPropertiesForSection = null;
|
||||||
if (fixedProperties.TryGetValue(section.IniSectionAttribute.Name, out fixedPropertiesForSection)) {
|
if (fixedProperties.TryGetValue(section.IniSectionAttribute.Name, out fixedPropertiesForSection)) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue