Re: Copying the path of files selected in Finder
Re: Copying the path of files selected in Finder
- Subject: Re: Copying the path of files selected in Finder
- From: Yvan KOENIG <email@hidden>
- Date: Sat, 29 Apr 2017 14:45:06 +0200
Le 29 avr. 2017 à 12:48, Jean-Christophe Helary < email@hidden> a écrit :
Yves, Thank you for the comments. On Apr 29, 2017, at 19:18, Yvan KOENIG <email@hidden> wrote:
I would made some changes because on my system - and I'm not the only one - hidden files are always visible. Without the changes the script list these visibles hidden files.
When I set all the files to be visible and I try your script I don't get a path for dotted files when they are selected. But the purpose of the script is to get the path of any selected file (even dotted files, if necessary), so why put that restriction in your modifications?
I dropped the visible/hidden files because most the time they are in the selection although I don't want them to appear. I don't want to get the DS_store or Icon files. If you don't want to drop these visible/hidden files you may drop the test. Even without these changes something is not accurate in the comments : the notification is able to display two paths - if they aren't more than 46 characters long.
Thank you. I could not find a reference to the display notifications" beyond what was in the ASLG. Can you tell me where you found that information?
I just look at what was displayed in the selection. When the files are deep in the hierarchy, I looked at what was displayed and saw that 46 characters were on the first line and the rest of the path was on the second line. In fact, it depends of the width of the available paths.
When the clipboard contains : "/Users/yvankoenig/Desktop/quotes/AAPL quote.scpt /Users/yvankoenig/Desktop/quotes/aapl.csv /Users/yvankoenig/Desktop/quotes/aapl.numbers /Users/yvankoenig/Desktop/quotes/get AAPL hebdo.scpt /Users/yvankoenig/Desktop/quotes/insertQuotes.scpt /Users/yvankoenig/Desktop/quotes/UserAgents Opera.rtfd"
The notification display : "/Users/yvankoenig/Desktop/quotes/AAPL quote.scpt /Users/yvankoenig/Desktop/quotes/aapl.csv /Users/…"
As you may see, in this case, there are 48 characters on the first line, 50 on the second one. I just discover that the linefeed between the 2nd and the 3rd path is replaced by a space.
Using an app able to measure what is on screen I saw that the limit is 285 pixels for a line.
Yvan KOENIG running Sierra 10.12.4 in French (VALLAURIS, France) samedi 29 avril 2017 14:44:50
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden