\hypertarget{external_elm_panes_8edc-example}{\section{external\-\_\-elm\-\_\-panes.\-edc}
}
This example shows E\-X\-T\-E\-R\-N\-A\-L elementary panes in action.


\begin{DoxyCodeInclude}
collections \{
   \textcolor{comment}{/* tell edje that we are going to use elementary external parts */}
   externals \{
      external: \textcolor{stringliteral}{"elm"};
   \}
   
   \textcolor{comment}{/* those groups are the buttons used as content for the panes */}
   group \{ name: \textcolor{stringliteral}{"button1"};
      parts \{
         part \{ name: \textcolor{stringliteral}{"btn"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/button"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               params.string: \textcolor{stringliteral}{"label"} \textcolor{stringliteral}{"Left"};
            \}
         \}
      \}
   \}
   group \{ name: \textcolor{stringliteral}{"button2"};
      parts \{
         part \{ name: \textcolor{stringliteral}{"btn"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/button"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               params.string: \textcolor{stringliteral}{"label"} \textcolor{stringliteral}{"Top"};
            \}
         \}
      \}
   \}
   group \{ name: \textcolor{stringliteral}{"button3"};
      parts \{
         part \{ name: \textcolor{stringliteral}{"btn"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/button"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               params.string: \textcolor{stringliteral}{"label"} \textcolor{stringliteral}{"Right"};
            \}
         \}
      \}
   \}

   \textcolor{comment}{/* this is the vertical panes */}
   group \{ name: \textcolor{stringliteral}{"panes2"};
      parts \{
         part \{ name: \textcolor{stringliteral}{"panes"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/panes"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               params \{
                  \textcolor{keywordtype}{bool}: \textcolor{stringliteral}{"horizontal"} 1;
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content left"} \textcolor{stringliteral}{"button2"};
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content right"} \textcolor{stringliteral}{"button3"};
               \}
            \}
         \}
      \}
   \}
   
   group \{ name: \textcolor{stringliteral}{"main"};
      \textcolor{comment}{/* set a min window size */}
      min: 300 400;

      parts \{
         part \{ name: \textcolor{stringliteral}{"bg"};
            type: RECT;
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               color: 255 255 255 255;
            \}
         \}

         part \{ name: \textcolor{stringliteral}{"title"};
            type: TEXT;
            effect: SOFT\_SHADOW;
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               color: 255 255 255 255;
               color3: 70 70 70 70;
               text \{
                  text: \textcolor{stringliteral}{"Elementary Panes"};
                  font: \textcolor{stringliteral}{"Sans"};
                  size: 16;
                  align: 0.5 0.0;
               \}
            \}
         \}

         \textcolor{comment}{/* first panes (horiz) */}
         part \{ name: \textcolor{stringliteral}{"panes1"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/panes"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               rel1.offset: 0 35;
               rel2.offset: 0 -45;
               params \{
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content left"} \textcolor{stringliteral}{"button1"};
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content right"} \textcolor{stringliteral}{"panes2"};
               \}
            \}
            description \{ state: \textcolor{stringliteral}{"swapped"} 0.0;
               inherit: \textcolor{stringliteral}{"default"} 0.0;
               params \{
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content left"} \textcolor{stringliteral}{"panes2"};
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"content right"} \textcolor{stringliteral}{"button1"};
               \}
            \}
         \}

         \textcolor{comment}{/* button used to swap the content of the panes1 */}
         part \{ name: \textcolor{stringliteral}{"swap\_button"};
            type: EXTERNAL;
            source: \textcolor{stringliteral}{"elm/button"};
            description \{ state: \textcolor{stringliteral}{"default"} 0.0;
               rel1 \{
                  relative: 0.0 1.0;
                  offset: 0 -40;
               \}
               params \{
                  \textcolor{keywordtype}{string}: \textcolor{stringliteral}{"label"} \textcolor{stringliteral}{"Swap & back"};
               \}
            \}
         \}
      \}

      programs \{
         \textcolor{comment}{/* when button is pressed set the 'swapped' state */}
         program \{ name: \textcolor{stringliteral}{"swap"};
            signal: \textcolor{stringliteral}{"clicked"};
            source: \textcolor{stringliteral}{"swap\_button"};
            action: STATE\_SET \textcolor{stringliteral}{"swapped"} 0.0;
            target: \textcolor{stringliteral}{"panes1"};
            after: \textcolor{stringliteral}{"go\_back"};
         \}
         \textcolor{comment}{/* after 1 second return to the 'default' state */}
         program \{ name: \textcolor{stringliteral}{"go\_back"};
            in: 1.0 0.0;
            action: STATE\_SET \textcolor{stringliteral}{"default"} 0.0;
            target: \textcolor{stringliteral}{"panes1"};
         \}
      \}
   \}
\}
\end{DoxyCodeInclude}
 