0

I want to create a grouped object with multiple lines and fill the object with a background color. As you can see, however, the background does not respect the lines as a frame.

enter image description here

Is it possible to fill only the grouped object within the lines?

ESCoder
  • 15,431
  • 2
  • 19
  • 42
Bowers
  • 836
  • 8
  • 20

1 Answers1

2

It's not possible using grouped lines (style will be applied to whole group which have shape of rectangle) , but you can create custom shape using Arrange > Insert > Shape. You can find description how to do that here or here. If you want to edit shape after inserting it, you can do that using Edit Shape from Style tab in format panel on right (it is also possible to edit some of draw.io shapes).

Example shape similar to your image:

<shape h="100" w="100" aspect="variable" strokewidth="inherit">  
  <foreground>    
    <path>      
      <move x="50" y="0" />
      <line x="80" y="40" />      
      <line x="100" y="50" />      
      <line x="60" y="100" />      
      <line x="30" y="100" />     
      <line x="0" y="60" />      
      <close />     
    </path>    
    <fillstroke />    
  </foreground>  
</shape>

Remeber to use <fillstroke /> or <fill /> if you want colored background.

Godric
  • 769
  • 7
  • 18