How to format the first line of a post differently?

Here is the idea

add_filter('the_content', 'testfunc');

function custom_formatter($matches){
  return "<strong>{$matches[0]}</strong>";
}

function testfunc($content)
{
  $pattern = "$\<p.*\>(.*)\<\/p\>$";
  $content = preg_replace_callback($pattern, 'custom_formatter', $content);
  return $content;
}

However, you will need a better regular expression in $pattern variable as this regex may be very poor. in the custom_formatter function you can do the formattings you want.