I am using Kivy in Python and only the last button has it's embedded objects appearing
Question: I apologize in advance if my question is stupid or obvious, but I have been
researching this over and over and am coming up with nothing. I am currently
using Kivy and have multiple buttons in a gridlayout, which is in a
scrollview. Withing these buttons I have a label and an image. Only the last
of my buttons shows the label and image whenever I run my code. I think it has
something to do with the positions, but I can't figure out what it is. Here is
my code:

    
    
        Window.clearcolor = (0.937, 0.698, 0.176, 1)
    
    class Solis(App):
        def build(self):
            b1 = Button(text= "",
                          background_color=(237, 157, 59, 1),
                          size_hint_y= None,
                          background_normal = '',
                          valign = 'middle',
    
    
                      font_size=20)
    
        lab1 = Label(text= Content1,
                    color= (0.937,  0.698, 0.176, 1),
                    valign= 'middle',
                    pos=(b1.x , b1.height / 2))
    
        b1I = AsyncImage(source = lead1image)
    
        def callback1(self):
            webbrowser.open(lead1)
    
        b1.bind(on_press=callback1)
    
        b2 = Button(text= "",
                      background_color=(237, 157, 59, 1),
                      size_hint_y= None,
                      background_normal = '',
                      valign = 'middle',
    
                      font_size=20)
    
        lab2 = Label(text= Content2,
                    color= (0.937, 0.698, 0.176, 1),
                    valign= 'middle',
                    halign= 'center',
                    pos=(b2.x + 800, b2.height))
    
        b2I = AsyncImage(source = lead2image)
    
        def callback2(self):
            webbrowser.open(lead2)
    
        b2.bind(on_press=callback2)
    
        b3 = Button(text= "",
                      background_color=(237, 157, 59, 1),
                      size_hint_y= None,
                      background_normal = '',
                      valign = 'middle',
    
                      font_size=20)
    
        lab3 = Label(text= Content3,
                    color= (0.937, 0.698, 0.176, 1),
                    valign= 'middle',
                    pos=(b3.x + 800, b3.height / 4))
    
        b3I = AsyncImage(source = lead3image)
    
        def callback3(self):
            webbrowser.open(lead3)
    
        b3.bind(on_press=callback3)
    
    
    
    
        l = GridLayout(cols=1, spacing=10, size_hint_y=None, orientation = 'vertical')
    
        l.bind(minimum_height=l.setter('height'))
    
        s = ScrollView(size_hint=(1, None), size=(Window.width, Window.height))
    
        s.add_widget(l)
        l.add_widget(b1)
        l.add_widget(b2)
        l.add_widget(b3)
        b1.add_widget(b1I)
        b1.add_widget(lab1)
        b2.add_widget(b2I)
        b2.add_widget(lab2)
        b3.add_widget(b3I)
        b3.add_widget(lab3)
    
    
        return s
    
    
    
    if __name__ == "__main__":
        Solis().run()
    

And here is my result [here](https://i.stack.imgur.com/CMkTi.png)


Answer: Here is something that should help you get what you want:

A main.py like this:

    
    
    from kivy.app import App
    import webbrowser
    
    class Solis(App):
    
        def __init__(self, **kwargs):
            super(Solis, self).__init__(**kwargs)
            self.lead1image='https://pbs.twimg.com/profile_images/562300519008333825/6WcGRXLU.png'
            self.lead2image='https://pbs.twimg.com/profile_images/439154912719413248/pUBY5pVj.png'
            self.lead3image='https://pbs.twimg.com/profile_images/424495004/GuidoAvatar.jpg'
    
        def callback(self,url):
            webbrowser.open(url)
    
     if __name__ == '__main__':
        Solis().run()
    

And a solis.kv like this:

    
    
    ScrollView:
    
        GridLayout:
            cols:1
            size_hint_y:None
            height: self.minimum_height
    
            Button:
                size_hint_y: None
                height:'50dp'
                on_press: app.callback(app.lead1image)
    
                AsyncImage:
                    id:im1
                    size_hint: None, None
                    height: self.parent.height
                    width: '48dp'
                    source: app.lead1image
                    pos: (self.parent.x, self.parent.y)
    
                Label:
                    size_hint: None, None
                    height:self.parent.height
                    width: self.parent.width - im1.width
                    text: 'Text for the 1st Label'
                    pos: (self.parent.x, self.parent.y)
    
            Button:         
                size_hint_y: None
                height:'50dp'
                on_press: app.callback(app.lead2image)
    
                AsyncImage:
                    size_hint: None, None
                    height: self.parent.height
                    width: '48dp'
                    source: app.lead2image
                    pos: (self.parent.x, self.parent.y)
    
                Label:
                    size_hint: None, None
                    height:self.parent.height
                    width: self.parent.width - im1.width
                    text: 'Text for the 2st Label'
                    pos: (self.parent.x, self.parent.y)
    
            Button:
                size_hint_y: None
                height:'50dp'
                on_press: app.callback(app.lead3image)
    
                AsyncImage:
                    size_hint: None, None
                    height: self.parent.height
                    width: '48dp'
                    source: app.lead3image
                    pos: (self.parent.x, self.parent.y)
    
                Label:
                    size_hint: None, None
                    height:self.parent.height
                    width: self.parent.width - im1.width
                    text: 'Text for the 2st Label'
                    pos: (self.parent.x, self.parent.y)
    

Thus, there is now two files (a ".py" and a ".kv"): This will help you
separate the logic of your application from its User Interface. Note that it
is possible to reduce the length of the code with some customized widgets.
Also, if you want to keep juste one .py file, I would add a "for" loop.
Finally, regarding your issue: I guess your labels and images were
superimposed. I avoided this by using "pos:".

