Photoshop JavaScript Reference ppsx

335 1.1K 1
Photoshop JavaScript Reference ppsx

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

bbc Adobe ® Photoshop ® cs2 Photoshop JavaScript Reference © 2005 Adobe Systems Incorporated. All rights reserved. Adobe® Creative Suite 2 Photoshop ® JavaScript Scripting Reference for Windows ® and Macintosh ® . NOTICE: All information contained herein is the property of Adobe Systems Incorporated. No part of this publication (whether in hardcopy or electronic form) may be reproduced or transmitted, in any form or by any means, electronic, mechanical, photocopying, recording, or otherwise, without the prior written consent of Adobe Systems Incorporated. The software described in this document is furnished under license and may only be used or copied in accordance with the terms of such license. This publication and the information herein is furnished AS IS, is subject to change without notice, and should not be construed as a commitment by Adobe Systems Incorporated. Adobe Systems Incorporated assumes no responsibility or liability for any errors or inaccuracies, makes no warranty of any kind (express, implied, or statutory) with respect to this publication, and expressly disclaims any and all warranties of merchantability, fitness for particular purposes, and noninfringement of third party rights. Any references to company names in sample templates are for demonstration purposes only and are not intended to refer to any actual organization. Adobe, the Adobe logo, Acrobat, GoLive, Illustrator, Photoshop are either registered trademarks or trademarks of Adobe Systems Incorporated in the United States and/or other countries. Apple, Mac OS, and Macintosh are trademarks of Apple Computer, Inc., registered in the United States and other countries. Microsoft, and Windows are either registered trademarks or trademarks of Microsoft Corporation in the United States and other countries. JavaScript and all Java-related marks are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries. UNIX is a registered trademark of The Open Group. All other trademarks are the property of their respective owners. If this guide is distributed with software that includes an end user agreement, this guide, as well as the software described in it, is furnished under license and may be used or copied only in accordance with the terms of such license. Except as permitted by any such license, no part of this guide may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, recording, or otherwise, without the prior written permission of Adobe Systems Incorporated. Please note that the content in this guide is protected under copyright law even if it is not distributed with software that includes an end user license agreement. The content of this guide is furnished for informational use only, is subject to change without notice, and should not be construed as a commitment by Adobe Systems Incorporated. Adobe Systems Incorporated assumes no responsibility or liability for any errors or inaccuracies that may appear in the informational content contained in this guide. Adobe Systems Incorporated, 345 Park Avenue, San Jose, California 95110, USA. 3 Contents 1 Introduction 37 Script Support in Adobe Photoshop CS2 37 JavaScript support 38 Executing scripts 38 Installing scripts 38 Executing other scripts 38 Startup scripts 38 Changes Since Earlier Versions 39 Changes in ScriptUI 39 2 JavaScript Object Reference 41 Working with the Properties Tables 41 displayDialogs 41 Working with the Methods Tables 41 executeAction 42 Working with Method Parameters 42 ActionDescriptor 43 Properties 43 count 43 typename 43 Methods 43 clear 43 erase 43 fromStream 43 getBoolean 43 getClass 43 getData 43 getDouble 43 getEnumerationType 43 getEnumerationValue 43 getInteger 43 getKey 43 getList 43 getObjectType 44 getObjectValue 44 getPath 44 getReference 44 getString 44 getType 44 getUnitDoubleType 44 getUnitDoubleValue 44 hasKey 44 isEqual 44 putBoolean 44 putClass 44 putData 44 Adobe Photoshop CS2 JavaScript Scripting Reference 4 putDouble 44 putEnumerated 44 putInteger 44 putList 45 putObject 45 putPath 45 putReference 45 putString 45 putUnitDouble 45 toStream 45 ActionList 46 count 46 typename 46 clear 46 getBoolean 46 getClass 46 getData 46 getDouble 46 getEnumerationType 46 getEnumerationValue 46 getInteger 46 getList 46 getObjectType 46 getObjectValue 47 getPath 47 getReference 47 getString 47 getType 47 getUnitDoubleType 47 getUnitDoubleValue 47 putBoolean 47 putClass 47 putData 47 putDouble 47 putEnumerated 47 putInteger 47 putList 47 putObject 47 putPath 47 putReference 48 putString 48 putUnitDouble 48 ActionReference 49 Properties 49 typename 49 Methods 49 getContainer 49 getDesiredClass 49 getEnumeratedType 49 getEnumeratedValue 49 getForm 49 Adobe Photoshop CS2 JavaScript Scripting Reference 5 getIdentifier 49 getIndex 49 getName 49 getOffset 49 getProperty 49 putClass 49 putEnumerated 50 putIdentifier 50 putIndex 50 putName 50 putOffset 50 putProperty 50 Application 51 Properties 51 activeDocument 51 backgroundColor 51 colorSettings 51 displayDialogs 51 documents 51 fonts 51 foregroundColor 51 freeMemory 51 locale 51 macintoshFileTypes 51 name 51 notifiers 52 notifiersEnabled 52 path 52 playbackDisplayDialogs 52 playbackParameters 52 preferences 52 preferencesFolder 52 scriptingVersion 52 typename 52 version 52 windowsFileTypes 52 Methods 53 batch 53 beep 53 bringToFront 53 charIDToTypeID 53 doAction 53 executeAction 53 executeActionGet 53 load 53 makeContactSheet 53 makePDFPresentation 53 makePhotoGallery 53 makePhotomerge 54 makePicturePackage 54 open 54 Adobe Photoshop CS2 JavaScript Scripting Reference 6 purge 54 stringIDToTypeID 54 typeIDToCharID 54 typeIDToStringID 54 Second Sample Script 56 ArtLayer 57 Properties 57 allLocked 57 blendMode 57 bounds 57 fillOpacity 57 grouped 57 isBackgroundLayer 57 kind 57 linkedLayers 57 name 58 opacity 58 parent 58 pixelsLocked 58 positionLocked 58 textItem 58 transparentPixelsLocked 58 typename 58 visible 58 Methods 58 adjustBrightnessContrast 58 adjustColorBalance 58 adjustCurves 58 adjustLevels 59 applyAddNoise 59 applyAverage 59 applyBlur 59 applyBlurMore 59 applyClouds 59 applyCustomFilter 59 applyDeInterlace 59 applyDespeckle 59 applyDifferenceClouds 59 applyDiffuseGlow 59 applyDisplace 59 applyDustAndScratches 60 applyGaussianBlur 60 applyGlassEffect 60 applyHighPass 60 applyLensBlur 60 applyLensFlare 60 applyMaximum 60 applyMedianNoise 60 applyMinimum 60 applyMotionBlur 60 applyNTSC 60 Adobe Photoshop CS2 JavaScript Scripting Reference 7 applyOceanRipple 60 applyOffset 61 applyPinch 61 applyPolarCoordinates 61 applyRadialBlur 61 applyRipple 61 applySharpen 61 applySharpenEdges 61 applySharpenMore 61 applyShear 61 applySmartBlur 61 applySpherize 61 applyStyle 61 applyTextureFill 62 applyTwirl 62 applyUnSharpMask 62 applyWave 62 applyZigZag 62 autoContrast 62 autoLevels 62 clear 62 copy 62 cut 62 desaturate 62 duplicate 63 equalize 63 invert 63 link 63 merge 63 mixChannels 63 move 64 photoFilter 64 posterize 64 rasterize 64 remove 64 resize 64 rotate 64 selectiveColor 65 shadowHighlight 65 threshold 65 translate 65 unlink 65 ArtLayers 68 Properties 68 length 68 parent 68 typename 68 Methods 68 index 68 add 68 getByName 68 Adobe Photoshop CS2 JavaScript Scripting Reference 8 removeAll 68 BatchOptions 69 Properties 69 destination 69 destinationFolder 69 errorFile 69 fileNaming 69 macintoshCompatible 69 overrideOpen 69 overrideSave 70 startingSerial 70 suppressOpen 70 suppressProfile 70 typename 70 unixCompatible 70 windowsCompatible 70 BitmapConversionOptions 71 Properties 71 angle 71 frequency 71 method 71 patternName 71 resolution 71 shape 71 typename 71 BMPSaveOptions 72 Properties 72 alphaChannels 72 depth 72 flipRowOrder 72 osType 72 rleCompression 72 typename 72 CameraRawOpenOptions 73 Properties 73 bitsPerChannel 73 blueHue 73 blueSaturation 73 brightness 73 chromaticAberrationBY 73 chromaticAberrationRC 73 colorNoiseReduction 73 colorSpace 73 contrast 73 exposure 73 greenHue 73 greenSaturation 73 luminanceSmoothing 73 redHue 73 redSaturation 73 resolution 73 Adobe Photoshop CS2 JavaScript Scripting Reference 9 saturation 73 settings 73 shadows 73 shadowTint 74 sharpness 74 size 74 temperature 74 tint 74 typename 74 vignettingAmount 74 vignettingMidpoint 74 whiteBalance 74 Channel 75 Properties 75 color 75 histogram 75 kind 75 name 75 opacity 75 parent 75 typename 76 visible 76 Methods 76 duplicate 76 merge 76 delete 76 Channels 77 Properties 77 length 77 parent 77 typename 77 Methods 77 index 77 add 77 getByName 77 removeAll 77 CMYKColor 82 Properties 82 black 82 cyan 82 magenta 82 typename 82 yellow 82 ContactSheetOptions 83 Properties 83 acrossFirst 83 bestFit 83 caption 83 columnCount 83 flatten 83 font 83 Adobe Photoshop CS2 JavaScript Scripting Reference 10 fontSize 83 height 83 horizontal 83 mode 83 resolution 83 rowCount 83 typename 83 useAutoSpacing 83 vertical 84 width 84 DCS1_SaveOptions 85 Properties 85 dCS 85 embedColorProfile 85 encoding 85 halftoneScreen 85 interpolation 85 preview 85 transferFunction 85 typename 85 vectorData 85 DCS2_SaveOptions 86 Properties 86 dCS 86 embedColorProfile 86 encoding 86 halftoneScreen 86 interpolation 86 multiFileDCS 86 preview 86 spotColors 86 transferFunction 86 typename 86 vectorData 86 Document 87 Properties 87 activeChannels 87 activeHistoryBrushSource 87 activeHistoryState 87 activeLayer 87 artLayers 87 backgroundLayer 87 bitsPerChannel 87 channels 87 colorProfileName 87 colorProfileType 87 componentChannels 88 fullName 88 height 88 histogram 88 historyStates 88 [...]... 151 Properties 151 Adobe Photoshop CS2 JavaScript Scripting Reference 21 alphaChannels 151 typename 151 PNGSaveOptions 152 Properties 152 interlaced 152 typename 152 Preferences 153 Properties ... Mac OS volumes 245 Windows drives 245 Adobe Photoshop CS2 JavaScript Scripting Reference 30 Aliases 246 Portability issues 246 Unicode I/O 246 File Error Handling 247 7 File and Folder Object Reference 248 Overview 248 File Object ... and Folder Supported Encoding Names 263 Additional encodings 263 8 Scripting Constants 265 AdjustmentReference 265 AnchorPosition 265 Adobe Photoshop CS2 JavaScript Scripting Reference 32 AntiAlias 265 AutoKernType 265 BatchDestinationType 265 BitmapConversionType... 271 GridLineStyle 271 GridSize 271 GuideLineStyle 271 Adobe Photoshop CS2 JavaScript Scripting Reference 33 IllustratorPathType 271 Intent 271 JavaScriptExecutionMode 271 Justification 271 Language 271 LayerCompression ... 112 Properties 112 colors 112 dither 112 ditherAmount 112 forced 112 Adobe Photoshop CS2 JavaScript Scripting Reference 15 interlaced 112 matte 112 palette 112 preserveExactColors 112 transparency ... 119 quality 119 scans 119 typename 119 LabColor 120 Properties 120 Adobe Photoshop CS2 JavaScript Scripting Reference 16 a 120 b 120 l 120 typename 120 LayerComp 121 Properties ... 125 layerSets 125 linkedLayers 125 name 125 opacity 125 parent 125 Adobe Photoshop CS2 JavaScript Scripting Reference 17 typename 125 visible 125 Methods 126 duplicate 126 link 126 merge... 131 typename 131 Methods 131 remove 131 Notifiers 132 Properties 132 Adobe Photoshop CS2 JavaScript Scripting Reference 18 length 132 parent 132 typename 132 Methods 132 index 132 add ... rightDirection 140 typename 140 PathPoints 141 Properties 141 length 141 Adobe Photoshop CS2 JavaScript Scripting Reference 19 parent 141 typename 141 index 141 PDFOpenOptions 142 Properties ... spotColors 144 tileSize 144 transparency 144 typename 144 useOutlines 145 Adobe Photoshop CS2 JavaScript Scripting Reference 20 vectorData 145 view 145 PhotoCDOpenOptions 146 Properties 146 colorProfileName . bbc Adobe ® Photoshop ® cs2 Photoshop JavaScript Reference © 2005 Adobe Systems Incorporated. All rights reserved. Adobe® Creative Suite 2 Photoshop ® JavaScript Scripting Reference for. getReference 44 getString 44 getType 44 getUnitDoubleType 44 getUnitDoubleValue 44 hasKey 44 isEqual 44 putBoolean 44 putClass 44 putData 44 Adobe Photoshop CS2 JavaScript Scripting Reference. Adobe Photoshop CS2 37 JavaScript support 38 Executing scripts 38 Installing scripts 38 Executing other scripts 38 Startup scripts 38 Changes Since Earlier Versions 39 Changes in ScriptUI 39 2 JavaScript

Ngày đăng: 11/07/2014, 04:20

Mục lục

  • Introduction

    • Script Support in Adobe Photoshop CS2

      • JavaScript support

      • Changes Since Earlier Versions

        • Changes in ScriptUI

        • JavaScript Object Reference

          • Working with the Properties Tables

            • displayDialogs

            • Working with the Methods Tables

              • executeAction

              • Working with Method Parameters

              • Action Manager

                • The ScriptListener Plug-In

                  • Installing ScriptListener

                  • Action Manager Scripting Objects

                  • Using the Action Manager from JavaScript

                  • ScriptUI Programming Model

                    • Creating a window

                    • Adding elements to containers

                      • Creation properties

                      • Modal dialogs

                        • Creating and using modal dialogs

                        • Dismissing a modal dialog

                        • Default and cancel elements

                        • Defining Behavior for Controls with Event Callbacks

                          • Defining event handler functions

                          • Automatic Layout

                            • Default layout behavior

                            • Automatic layout properties

                              • Container orientation

                              • Determining a preferred size

                              • Creating more complex arrangements

                              • Custom layout manager example

                              • Example scripts

                                • Alert box builder

                                  • Resource specification example

Tài liệu cùng người dùng

Tài liệu liên quan