legend children empty, but need to set transparency
3 次查看(过去 30 天)
显示 更早的评论
Hi y'all,
I'm trying to alter the transparency(alpha) of a legend object (the dark blue patch) to match my plot, but when I try to access the children to set the alpha it is empty for some reason? Any idea why this would be or how I could fix it?
Thanks and all the best, Kate
get(legend)
AutoUpdate: 'on'
BeingDeleted: 'off'
Box: 'off'
BusyAction: 'queue'
ButtonDownFcn: @bdowncb
Children: [0×0 GraphicsPlaceholder]
Color: [1 1 1]
CreateFcn: ''
DeleteFcn: ''
EdgeColor: [0.1500 0.1500 0.1500]
FontAngle: 'normal'
FontName: 'Helvetica'
FontSize: 16.2000
FontWeight: 'normal'
HandleVisibility: 'on'
HitTest: 'on'
Interpreter: 'tex'
Interruptible: 'off'
ItemHitFcn: @defaultItemHitCallback
LineWidth: 0.5000
Location: 'northeast'
Orientation: 'vertical'
Parent: [1×1 Figure]
PickableParts: 'visible'
Position: [0.5268 0.7071 0.3607 0.1940]
Selected: 'off'
SelectionHighlight: 'on'
String: {'Land Sink of Carbon' 'Global Photosynthesis' 'Integrated Respiration' 'Current Climate'}
Tag: 'legend'
TextColor: [0 0 0]
Title: [1×1 Text]
Type: 'legend'
UIContextMenu: [1×1 ContextMenu]
Units: 'normalized'
UserData: []
Visible: 'on'
0 个评论
回答(1 个)
Anton Semechko
2018-6-12
I had the same problem. I couldn't figure out a way to resolve it in Matlab, so instead I exported the graph as it was and then edited the legend in the free photo editing program called paint.net. Though you can use any photo editing program of your choice.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Legend 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!