mirror of
https://github.com/greenshot/greenshot
synced 2025-08-14 02:37:03 -07:00
Added settings forms for DropShadowEffect & TornEdgeEffect
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2380 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
6579d49d49
commit
38de4875e0
10 changed files with 696 additions and 31 deletions
36
Greenshot/Forms/TornEdgeSettingsForm.cs
Normal file
36
Greenshot/Forms/TornEdgeSettingsForm.cs
Normal file
|
@ -0,0 +1,36 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using Greenshot.Core;
|
||||
using GreenshotPlugin.Core;
|
||||
|
||||
namespace Greenshot.Forms {
|
||||
public partial class TornEdgeSettingsForm : BaseForm {
|
||||
private TornEdgeEffect effect;
|
||||
public TornEdgeSettingsForm(TornEdgeEffect effect) {
|
||||
this.effect = effect;
|
||||
InitializeComponent();
|
||||
this.Icon = GreenshotResources.getGreenshotIcon();
|
||||
trackBar1.Value = (int)(effect.Darkness * 40);
|
||||
offsetX.Value = effect.ShadowOffset.X;
|
||||
offsetY.Value = effect.ShadowOffset.Y;
|
||||
toothsize.Value = effect.ToothHeight;
|
||||
verticaltoothrange.Value = effect.VerticalToothRange;
|
||||
horizontaltoothrange.Value = effect.HorizontalToothRange;
|
||||
}
|
||||
|
||||
private void buttonOK_Click(object sender, EventArgs e) {
|
||||
effect.Darkness = (float)trackBar1.Value / (float)40;
|
||||
effect.ShadowOffset = new Point((int)offsetX.Value, (int)offsetY.Value);
|
||||
effect.ShadowSize = (int)thickness.Value;
|
||||
effect.ToothHeight = (int)toothsize.Value;
|
||||
effect.VerticalToothRange = (int)verticaltoothrange.Value;
|
||||
effect.HorizontalToothRange = (int)horizontaltoothrange.Value;
|
||||
DialogResult = DialogResult.OK;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue