edit config.txt
uncomment and change the following lines:
hdmi_force_hotplug=1 # use for non-hdmi screen
hdmi_group=2 # computer monitor
hdmi_mode=81 # 1366x768@60Hz (16 for 1024x768@60Hz)
sdtv_aspect=3 # 16:9
more details about the config.txt:
http://elinux.org/RPiconfig#Video_mode_options