Naminari.Auto is a library designed to simplify task automation by providing users with the ability to control their mouse and keyboard inputs. With Naminari.Auto, you can easily create scripts that simulate user input without the need for manual input.
- Windows: .NET 8, .NET 9
using AutoClicker.Actions;var position = Mouse.GetPosition();var color = Mouse.GetPosition().GetPixelColor();Task.Run(async () =>
{
// Left Click
await Naminari.Auto.Mouse.ClickAsync(mouseButtons: MouseButtons.Left);
// Left Double Click
await Naminari.Auto.Mouse.ClickAsync(mouseButtons: MouseButtons.Left, clickTypes: Naminari.Auto.Models.ClickTypes.Double);
});Task.Run(async () =>
{
// Hold Left Click
await Naminari.Auto.Mouse.HoldAsync(mouseButtons: MouseButtons.Left);
// Release Left Click
await Naminari.Auto.Mouse.ReleaseAsync(mouseButtons: MouseButtons.Left);
});// Declare
Keyboard keyboard = new Keyboard();
// Only keep lastest process
keyboard.IsKeepLatestProcess = true;
// Click to any proccess windows and get list
keyboard.ProcessesTask.Run(async () =>
{
await Naminari.Auto.Keyboard.TypingAsync("Hello World!!!", "notepad++");
});// To select all text in Notepad++, hold down the Ctrl key and press the A key.
Task.Run(async () =>
{
await Auto.Keyboard.CommandAsync("Ctrl+A", "notepad++");
});
// To open Test Explorer in Visual Studio 2022, hold down the Ctrl key and press the A key, then release both keys and press the T key
Task.Run(async () =>
{
await Auto.Keyboard.CommandAsync("Ctrl+E,T", "devenv");
});Naminari.Auto.Utils.GetScreenShot()Rectangle area = new Rectangle
(Math.Min(startPoint.X, e.Location.X),
Math.Min(startPoint.Y, e.Location.Y),
Math.Abs(startPoint.X - e.Location.X),
Math.Abs(startPoint.Y - e.Location.Y));
Bitmap bmp = Naminari.Auto.Utils.GetImageFromSelect(area);
pictureBox.Image = bmp;var bigImage = new Bitmap(bigSource);
var smallImage = new Bitmap(smallSource);
var position = Utils.FindImagePosition(smallImage, bigImage);Take a look at the sample app that is included with the source code
We welcome contributions to our project! Before getting started, please take a moment to read through the following guidelines:
If you have found a bug in our project, please open an issue on GitHub. When reporting a bug, please include as much detail as possible about the issue and steps to reproduce it.
- Clone "contributors" branch.
- Add some nice features.
- Create a Pull Request to "develop" branch.
By contributing to our project, you agree that your contributions will be licensed under the LICENSE.txt
