You can pass in the needed Creation Properties like this:
obj = w.add('panel', [45,50,350,135], 'Title', { alignChildren : 'fill', orientation : 'row', margins : 15 } );
or (probably) set them manually like this:
obj = w.add('panel', [45,50,350,135], 'Title');
obj.alignChildren = 'fill';
obj.orientation = 'row';
obj.margins = 15;