-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
Description
Hey community
I am wondering does excelize 2.8.1 support set up color transparency for the addShape function?
Context:
I want to set up color transparency for the addShape which will help better display for shape line.
I attached the screenshot for the expected behavior, not sure we can setup solid color fill for one of ellipse I add it.
Ideally, if add color transparency then we can better visualize the overlap line.
image

Here is snap of code to generate two ellipses.
Below code will generate two ellipses with two solid color, but no color transparency.
Steps to reproduce the issue
if err := f.AddShape(sheetName, &excelize.Shape{
Type: "ellipse",
Cell: "C3",
Width: uint(diaComp),
Height: uint(diaComp),
Line: excelize.ShapeLine{
Color: "000000",
},
Fill: excelize.Fill{
Type: "pattern", Pattern: 1,
Color: []string{"#005996"},
},
}); err != nil {
return fmt.Errorf("some thing wrong in the first ellipse %w", err)
}
if err := f.AddShape(sheetName, &excelize.Shape{
Type: "ellipse",
Cell: "F3",
Width: uint(diaFox),
Height: uint(diaFox),
Line: excelize.ShapeLine{
Color: "000000",
},
Fill: excelize.Fill{
Type: "pattern", Pattern: 1,
Color: []string{"#66DBD1"},
},
}); err != nil {
return fmt.Errorf("some thing wrong in the second ellipse %w", err)
}
Describe the results you received
The color transparency still same
Describe the results you expected
I expected to see the color transparency has percentage setup
Go version
1.23.8
Excelize version or commit ID
2.8.1
Environment
Microsoft Excel Version 16.100
Validations
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- The provided reproduction is a minimal reproducible example of the bug.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request
Type
Projects
Status
Features