Stroke color of shapes in containers

I tried to use containers. As a result, the stroke of shapes became black:

How I can fix it? My code:

[lua]local function getShape( shape )

    if( shape == ‘circle’ ) then
        shape = display.newCircle( 0, 0, 50 )
    elseif( shape == ‘rect’ ) then
        shape = display.newRect( -50, -50, 100, 100 )
    end
    
    shape.strokeWidth = 15
    shape:setStrokeColor( 255, 0, 0 )
    shape:setFillColor( 255, 255, 0 )
    
    return shape
end

local circle1, circle2 = getShape( ‘circle’ ), getShape( ‘circle’ )

circle1:translate( 100, 100 )

circle2:translate( 100, 250 )

local rect1, rect2 = getShape( ‘rect’ ), getShape( ‘rect’ )

rect1:translate( 250, 100 )

rect2:translate( 250, 250 )

local group = display.newGroup( )

local container = display.newContainer( 350, 350 )

display.newText( ‘Group:’, 30, 20 ):setTextColor( 0 )

display.newText( ‘Container:’, 30, 170 ):setTextColor( 0 )

group:insert( circle1 )

group:insert( rect1 )

container:insert( circle2 )

container:insert( rect2 )[/lua]

display.newContainer is a feature of the new Graphics 2.0 system which has not been released yet.  You must have stumbled upon some routines that are there for us to test.   Because this is not released/surfaced yet, there is no guarantee that the behavior is functional.  There is no guarantee that the specifications will not change between now and release.

Playing with un-released features can be fun and challenging but I would not spend too much energy asking it to work as expected.  When we get closer to something stable, we will invite people to the beta.  At that point we would welcome people to try it and report problems they find.  But for now, there isn’t much we can do to help you.

display.newContainer is a feature of the new Graphics 2.0 system which has not been released yet.  You must have stumbled upon some routines that are there for us to test.   Because this is not released/surfaced yet, there is no guarantee that the behavior is functional.  There is no guarantee that the specifications will not change between now and release.

Playing with un-released features can be fun and challenging but I would not spend too much energy asking it to work as expected.  When we get closer to something stable, we will invite people to the beta.  At that point we would welcome people to try it and report problems they find.  But for now, there isn’t much we can do to help you.