Lavorare con l effetto Reflex della forma o del grafico
Possibili Scenari di Utilizzo
Aspose.Cells fornisce la proprietà Shape.ReflectionEffect per lavorare con l’effetto reflex della forma o del grafico. Contiene le seguenti sottoproprietà che è possibile impostare per ottenere risultati diversi secondo le proprie esigenze.
- ReflectionEffect.Blur
- ReflectionEffect.Direction
- ReflectionEffect.Distance
- ReflectionEffect.FadeDirection
- ReflectionEffect.RotWithShape
- ReflectionEffect.Size
- ReflectionEffect.Transparency
- ReflectionEffect.Type
La seguente schermata mostra l’interfaccia di Microsoft Excel per impostare l' Effetto Riflessione di una Forma.
Lavorare con l’Effetto Riflessione di una Forma o di un Grafico
Il seguente codice di esempio carica il file excel di origine e accede alla prima forma nel primo foglio di lavoro, imposta le sottoproprietà della proprietà Shape.ReflectionEffect e quindi salva il documento di lavoro nel file excel di output.
Codice di Esempio
// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-Java | |
// The path to the documents directory. | |
String dataDir = Utils.getSharedDataDir(WorkingWithReflectionEffect.class) + "articles/"; | |
// Load your source excel file | |
Workbook wb = new Workbook(dataDir + "WorkingWithReflectionEffect_in.xlsx"); | |
// Access first worksheet | |
Worksheet ws = wb.getWorksheets().get(0); | |
// Access first shape | |
Shape sh = ws.getShapes().get(0); | |
// Set the reflection effect of the shape | |
// Set its Blur, Size, Transparency and Distance properties | |
ReflectionEffect re = sh.getReflection(); | |
re.setBlur(30); | |
re.setSize(90); | |
re.setTransparency(0); | |
re.setDistance(80); | |
// Save the workbook in xlsx format | |
wb.save(dataDir + "WorkingWithReflectionEffect_out.xlsx"); |