Answers:
无法强制图标自动向左移动(并保持按您选择的条件排列)。
解决方法是,您可以在Finder中更改“ 查看选项”,以不按任何标准排列项目,并在左侧手动放置图标。
请参阅Mac基础:修改窗口以获取更多信息。
还可以通过Mac Basics页面来了解有关使用Mac的更多信息。
这不是最好的解决方案,但是如果没有其他措施,它就可以工作...
将以下代码粘贴到applescript文本框中:
-- https://gist.github.com/mrienstra/8330528
-- Based on http://www.tuaw.com/2012/12/24/applescript-desktop-icon-race/
-- Inspired by http://namesakecomic.com/comic/happy-new-year-from-namesake/#comment-1182035013
-- Rearranges Desktop icons to flow from left to right, top to bottom.
-- To have this run automatically every time files are added or removed from the Desktop, set this script to run as a Desktop "Folder Action". (See https://developer.apple.com/library/mac/documentation/applescript/conceptual/applescriptlangguide/reference/ASLR_folder_actions.html )
-- This is currently a rough proof-of-concept. It has only been tested with OS X 10.8.5 (Mountain Lion).
-- Current known limitations: Does not work with "Label position" set to "Right" (specifically, icons will overlap).
-- Adjust these for different spacing
property theSpacingFactor : 1.0
property theGutterXFactor : 0.57
property theGutterYFactor : 0.57
on rearrangeDesktopIcons()
tell application "Finder"
tell icon view options of window of desktop
set theArrangement to arrangement
set theArrangementString to theArrangement as string
if {"not arranged", "«constant ****narr»", "snap to grid", "«constant ****grda»"} does not contain theArrangementString then
display alert "\"Rearrange Desktop Icons\" AppleScript says:" message "Cannot rearrange Desktop items, please change Desktop \"Sort by\" to \"None\" or \"Snap to Grid\"." giving up after 10
return
end if
set theIconSize to icon size
set theLabelSize to text size
end tell
set theDesktopBounds to bounds of window of desktop
set theDesktopWidth to item 3 of theDesktopBounds
set theDesktopHeight to item 4 of theDesktopBounds
-- Retrieve a list of items on the desktop
set theDesktopItems to every item of desktop
set theContestantOffset to theIconSize / 2
set theSpacing to (theIconSize + theLabelSize + theContestantOffset) * theSpacingFactor
set theGuttersX to theSpacing * theGutterXFactor
set theGuttersY to theSpacing * theGutterYFactor
set theMaxColumns to ((theDesktopWidth - theGuttersX * 2) / theSpacing) as integer
set theMaxRows to ((theDesktopHeight - theGuttersY * 2) / theSpacing) as integer
set theMaxLocations to theMaxRows * theMaxColumns
set y to 1
repeat with a from 1 to length of theDesktopItems
set x to a mod theMaxColumns
if x is 0 then
set x to theMaxColumns
end if
if a is greater than theMaxLocations then
set desktop position of item a of theDesktopItems to {theGuttersX, theGuttersY}
else
set desktop position of item a of theDesktopItems to {theGuttersX + (x - 1) * theSpacing, theGuttersY + (y - 1) * theSpacing}
end if
if a mod theMaxColumns is 0 then
set y to y + 1
end if
end repeat
end tell
end rearrangeDesktopIcons
on adding folder items to alias after receiving listOfAlias
rearrangeDesktopIcons()
end adding folder items to
on removing folder items from alias after losing listOfAliasOrText
rearrangeDesktopIcons()
end removing folder items from
rearrangeDesktopIcons()
因此,每当文件添加到桌面时,所有文件都会按字母顺序重新排列...
按照所需的顺序组织所有文件夹。然后在“查看”下点击“清理”。这样可以很好地对齐所有内容。然后,您只需突出显示所有文件夹,然后将它们精确定位在所需位置即可。Macs不在左侧组织文件夹,仅在右侧组织文件夹,但是通过几个简单的步骤,您就可以在左侧整齐地组织所有内容。