If layer is in editing mode, show the pencil icon instead of embedded legend icon