it's reader with code source , nothing fancy , some methods of copy,past,cut,select,delete,read,readAndClean also catching ctrl+a to select all , ctrl+r to read
it read throw instance of SpVoice at SpeechLib. , it's voice is so damn weird and talking pretty fast but it helps me when im multi tasking or too lazy to read :P
feel free to correct any mistakes in the code (if there :P)
it may not be the best way to get it done but im still learning :)
code source
P.S add the SpeechLib as ref. u will find it at COMponent refs
i don't use spaces at methods so i can see as many as possible (sorry if u don't like it that way or not used to it like that :rolleyes:)
P.S design is just strip menu and textbox , ill upload it anyway
[Only registered and activated users can see links. Click Here To Register...]
for ss
[Only registered and activated users can see links. Click Here To Register...]
it read throw instance of SpVoice at SpeechLib. , it's voice is so damn weird and talking pretty fast but it helps me when im multi tasking or too lazy to read :P
feel free to correct any mistakes in the code (if there :P)
it may not be the best way to get it done but im still learning :)
code source
P.S add the SpeechLib as ref. u will find it at COMponent refs
Code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using SpeechLib;
namespace Reader
{
public partial class Form1 : Form
{
public Form1(){InitializeComponent();}
string toread;
void talk(string tosay){
SpVoice voice = new SpVoice();voice.Volume = 100;
voice.Speak(tosay, SpeechVoiceSpeakFlags.SVSFDefault);}
private void readToolStripMenuItem_Click(object sender, EventArgs e){
if (textBox1.SelectedText == "")toread = textBox1.Text;else toread = textBox1.SelectedText;talk(toread);}
private void readAndCleanToolStripMenuItem_Click(object sender, EventArgs e){
if (textBox1.SelectedText == "")toread = textBox1.Text;
else toread = textBox1.SelectedText;talk(toread);textBox1.Text = "";}
private void readOnlyToolStripMenuItem_Click(object sender, EventArgs e){
if (textBox1.SelectedText == "")toread = textBox1.Text;
else toread = textBox1.SelectedText;talk(toread);}
private void selectAllToolStripMenuItem1_Click(object sender, EventArgs e){
textBox1.SelectionStart = 0;textBox1.SelectionLength = textBox1.TextLength;}
private void textBox1_KeyPress(object sender, KeyPressEventArgs e){
if (e.KeyChar == (char)1){textBox1.SelectionStart = 0;textBox1.SelectionLength = textBox1.TextLength;}
if (e.KeyChar == (char)18){readOnlyToolStripMenuItem_Click(this.textBox1, e);}}
private void deselectAllToolStripMenuItem_Click(object sender, EventArgs e){textBox1.SelectionLength = 0;}
private void deleteAllToolStripMenuItem_Click(object sender, EventArgs e){textBox1.SelectedText = "";}
private void deleteSelectedToolStripMenuItem_Click(object sender, EventArgs e){textBox1.SelectedText = "";}
private void deleteAllToolStripMenuItem1_Click(object sender, EventArgs e){textBox1.Text = "";}
private void cutSelectedToolStripMenuItem_Click(object sender, EventArgs e){
Clipboard.SetText(textBox1.SelectedText, System.Windows.Forms.TextDataFormat.UnicodeText);textBox1.SelectedText = "";}
private void cutToolStripMenuItem_Click(object sender, EventArgs e){
try { Clipboard.SetText(textBox1.SelectedText, System.Windows.Forms.TextDataFormat.UnicodeText); textBox1.SelectedText = ""; }catch { };}
private void cutAllToolStripMenuItem_Click(object sender, EventArgs e){
Clipboard.SetText(textBox1.Text, TextDataFormat.UnicodeText);textBox1.Text = "";}
private void copyAllToolStripMenuItem_Click(object sender, EventArgs e){Clipboard.SetText(textBox1.Text, TextDataFormat.UnicodeText);}
private void copySelectedToolStripMenuItem_Click(object sender, EventArgs e){
Clipboard.SetText(textBox1.SelectedText, System.Windows.Forms.TextDataFormat.UnicodeText);}
private void copyToolStripMenuItem_Click(object sender, EventArgs e){
Clipboard.SetText(textBox1.SelectedText, System.Windows.Forms.TextDataFormat.UnicodeText);}
private void pasteToolStripMenuItem1_Click(object sender, EventArgs e){textBox1.Paste(Clipboard.GetText());Clipboard.Clear();}
}
}
P.S design is just strip menu and textbox , ill upload it anyway
[Only registered and activated users can see links. Click Here To Register...]
for ss
[Only registered and activated users can see links. Click Here To Register...]