Re: Questions about embedded photos in email


Pranav Lal
 

Hi Deborah,

If you navigate graphic by graphic, then yes, you will know of all images. You can use the new OCR feature in NVDA to check each graphic. However, I use the following script to pull images from outlook and recognize them. Keep the message that you want to check open. You can modify the below script to save the images into a folder so that you have better control.

#-------------------------------------------------------------------------------
# Name: module1
# Purpose:
#
# Author: Pranav Lal
#
# Created: 27/03/2015
# Copyright: (c) user 2015
# Licence: <your licence>

import win32com.client
import os
from PIL import Image

import pytesseract
import imghdr
import tempfile

def isImage(fp):
result=''
try:
result=imghdr.what(fp)
except:
pass
return result
def recogniseFile(fp):
img=Image.open(fp)
img1=img.convert('L')

print(pytesseract.image_to_string(img1))


def main():
pass

if __name__ == '__main__':
main()
o=win32com.client.Dispatch("Outlook.Application")
tp=tempfile.gettempdir()
curSel=o.ActiveExplorer()
curMSG=curSel.Selection.Item(1)
attachments=curMSG.Attachments
for attachment in attachments:
t=os.path.join(tp, attachment.FileName)
attachment.SaveAsFile(t)
r=isImage(t)
if not r:
pass
else:
recogniseFile(t)

os.remove(t)

-----Original Message-----
From: nvda@nvda.groups.io [mailto:nvda@nvda.groups.io] On Behalf Of Deborah Armstrong
Sent: Monday, October 09, 2017 1:00 AM
To: nvda@nvda.groups.io
Subject: [nvda] Questions about embedded photos in email

I'm editing a newsletter for an all-volunteer organization. Everyone keeps sending me pictures embedded in email rather than attachments.


My husband, who is sighted explained that they just drag and drop the
picture in to the email and that's why it shows as part of the email
rather than an attachment.


I have someone else doing the layout, but I'm frustrated that I might be
missing some of the photos. I mean can I be absolutely sure that a
screen reader will tell me when a photo is there and let me right-click
on it to save it as a separate file?


I use Windows 10 mail, Windows Live Mail and Thunderbird. I'm not
entirely happy with any of them; I use Outlook and JAWS at work with
fewer access glitches.


But at home it's NVDA and Narrator on Windows 10 with these clients.


What are thoughts from others on the list?


--Debee

Join nvda@nvda.groups.io to automatically receive all group messages.