implemented rectangular behavior!