title: toggle visibility of chain group in constraint layout
body: <p>In previous xml layout, I have multiple view groups with few elements inside. Hide each view group will also hide all of its child elements. Since I wanted to have flat structure and tried <strong>ConstraintLayout</strong>. Cool I know how to chain element with spread to align properly. Since flat structure does not have wrapped <strong>LinearLayout</strong>, now i have 3 views to hide instead. I would like to know if there is alternative to achieve this.</p>
  
  <p><strong>Without constraint layout</strong></p>
  
  <pre><code>&lt;RelativeLayout....
  ..........
  ..........
  &lt;LinearLayout
          android:visibility="gone"
          tools:visibility="visible"
          android:id="@+id/filter_area"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"&gt;
  
          &lt;android.support.v7.widget.AppCompatTextView
              android:id="@+id/lblTerminal"
              android:background="@color/lightGray"
              style="@style/PurpleSubtitle"
              android:drawableRight="@drawable/i_down_yellow"
              android:drawableEnd="@drawable/i_down_yellow"
              android:padding="10dp"
              android:text="@string/lblTerminal"
              android:layout_weight="5"
              android:layout_width="0dp"
              android:layout_height="wrap_content" /&gt;
  
          &lt;View
              android:background="@android:color/black"
              android:layout_width="1dp"
              android:layout_height="match_parent"/&gt;
  
          &lt;android.support.v7.widget.AppCompatTextView
              android:id="@+id/lblCategory"
              android:background="@color/lightGray"
              android:padding="10dp"
              android:drawableRight="@drawable/i_down_yellow"
              android:drawableEnd="@drawable/i_down_yellow"
              style="@style/PurpleSubtitle"
              android:text="@string/lblCategory"
              android:layout_weight="5"
              android:layout_width="0dp"
              android:layout_height="wrap_content" /&gt;
  
  
      &lt;/LinearLayout&gt;
    .......
    .......
    &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p><strong>With constraint layout</strong></p>
  
  <pre><code>    &lt;android.support.constraint.ConstraintLayout
      .....
      .....
      .....
         #happy that i no longer need LinearLayout for align properly
         &lt;android.support.v7.widget.AppCompatTextView
              android:id="@+id/lblTerminal"
              android:background="@color/lightGray"
              style="@style/PurpleSubtitle"
              android:drawableRight="@drawable/i_down_yellow"
              android:drawableEnd="@drawable/i_down_yellow"
              android:padding="10dp"
              android:text="@string/lblTerminal"
              android:layout_weight="5"
              android:layout_width="0dp"
              android:layout_height="50dp"
              app:layout_constraintTop_toBottomOf="@+id/txt_search"
              app:layout_constraintRight_toLeftOf="@+id/view3"
              app:layout_constraintLeft_toLeftOf="@+id/guideline2"
              app:layout_constraintHorizontal_chainStyle="spread"/&gt;
  
          &lt;View
              android:background="@android:color/black"
              android:layout_width="1dp"
              android:layout_height="50dp"
              android:id="@+id/view3"
              app:layout_constraintTop_toBottomOf="@+id/txt_search"
              app:layout_constraintRight_toLeftOf="@+id/lblCategory"
              app:layout_constraintLeft_toRightOf="@+id/lblTerminal" /&gt;
  
          &lt;android.support.v7.widget.AppCompatTextView
              android:id="@+id/lblCategory"
              android:background="@color/lightGray"
              android:padding="10dp"
              android:drawableRight="@drawable/i_down_yellow"
              android:drawableEnd="@drawable/i_down_yellow"
              style="@style/PurpleSubtitle"
              android:text="@string/lblCategory"
              android:layout_width="0dp"
              android:layout_height="50dp"
              app:layout_constraintTop_toTopOf="@+id/view3"
              app:layout_constraintRight_toRightOf="parent"
              app:layout_constraintLeft_toRightOf="@+id/view3" /&gt;
  
  
  
    ......
    ......
    ......
  
    &lt;/android.support.constraint.ConstraintLayout&gt;
  </code></pre>