title: Android Spinner Item Layout for Default Entries in XML
body: <p>I have two Spinners. One of them is populated on run-time.</p>
  
  <pre><code>groupSpinner.setAdapter(new ArrayAdapter&lt;&gt;(this,
                   android.R.layout.simple_spinner_item, groupNames));
  </code></pre>
  
  <p>The other one is pre-populated in the XML layout using a String array.</p>
  
  <pre><code>&lt;Spinner ...
      android:entries="@array/my_items_here" /&gt;
  </code></pre>
  
  <p>Both Spinners appear fine. However, when their items are shown, the children layouts do not match, both in <code>dropdown</code> and in <code>dialog</code> mode.
  I must be missing something very simple, but <strong>how can I set them to use the same layout</strong> (hopefully <code>android.R.layout.simple_spinner_item</code>), without creating my own custom layout, or loading the XML String array on run-time?</p>
  
  <p>It seems a basic thing to do, but I cannot find an answer and I have searched a lot, already.</p>
  
  <p>See screenshots, below:</p>
  
  <p><a href="https://i.stack.imgur.com/dVrpR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dVrpR.png" alt="Programmatically Populated Spinner"></a>
  <a href="https://i.stack.imgur.com/RU88V.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/RU88V.png" alt="XML Pre-populated Spinner"></a></p>
  
  <p>*Please forgive the use of Greek characters in the second image. I have checked and confirmed that the problem is not related to the use of Greek characters.</p>