using System;
// Suggested HotKey: Alt + Ctrl + L
public static class ClipboardFusionHelper
{
	public static string ProcessText(string text)
	{
		// Setup.
		string clipboardText = text; // Get clipboard.
		string selectedText = string.Empty;
		BFS.Clipboard.CopyText(out selectedText); // Get selected text.
		if( string.IsNullOrWhiteSpace(selectedText))
		{
			text = clipboardText; // Operate on the clipboard text.
		}
		else
		{
			text = selectedText; // Operate on the selected text.
		}
		// End early if no text found.
		if(string.IsNullOrEmpty(text))
		{
			return null;
		}
		// Main.
		text = text.ToLower();
		// Wrapup.
		BFS.Clipboard.PasteText(text);
		return null;
	}
}