如何在c#中获取屏幕阅读器? [英] How to get screen reader in c#?

查看:117
本文介绍了如何在c#中获取屏幕阅读器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在我的c#app中添加屏幕阅读器。屏幕阅读器应阅读屏幕上显示的任何内容(pdf,word,txt或网页等)。我试过搜索它,但没有得到任何适当的解决方案。请帮忙。

I want to add screen reader in my c# app. The screen reader should read whatever(pdf, word,txt,or website page, etc.) appears on the screen. I tried searching it but didn't got any proper solution. Please help.

推荐答案

.NET或Visual C#langauge本身没有Screen Reader。然而,可以在应用程序中将屏幕作为Graphics对象进行访问,然后您可以使用某种OCR或OMR服务从您保存的图形或图像中读取字符。我可以给你一个如何获得屏幕截图的例子,它可以帮助你将屏幕内容放到Bitmap上,保存为图像。



一次完成后,您可以使用OCR将这些字符作为字符串读取,依此类推。



阅读本文使用C#保存屏幕截图,AKA控制台监视器 [ ^ ]。您可以从 MSDN Gallery中下载Microsoft OCR库的示例代码 [ ^ ]。



但是如果你还想开发一个,你应该去阅读MSFT的辅助功能概述。他们有一套文档供您开始构建应用程序,以便为您提供屏幕上显示的语音结果。但是,网站已经包含了辅助功能和 ARIA [ ^ ]属性就是其中之一。



http:// msdn.microsoft.com/en-us/library/windows/desktop/bb735024.aspx [ ^ ]
There is no Screen Reader in .NET or in Visual C# langauge itself. The screen can be however accessed as a Graphics object in your application, and then you can use some sort of OCR or OMR service to read the characters from the graphics or image you save. I can give you an example of how to get the screen shot, which would help you to get the screen's content onto a Bitmap, for saving as an Image.

Once done, you can use an OCR to read those characters as string and so on.

Read this Saving a Screenshot Using C#, A.K.A "Console Monitor"[^]. You can go and download this sample code for the Microsoft OCR libary from MSDN Gallery[^].

But if you still want to develop one, you should go and read the MSFT's Accessibility overview. They have a set of documents for you to get started in building an application that would provide you the the spoken results that appear on the screen. However, websites already include the accessibility features and ARIA[^] property is one of them.

http://msdn.microsoft.com/en-us/library/windows/desktop/bb735024.aspx[^]


这篇关于如何在c#中获取屏幕阅读器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆