I have a dual-boot MacBook Pro with multiple partitions - of which most are not MacOS partitions.
I'd like to have a backup program that backs up the entire drive including all partitions.
Can Time Machine do that?
Time Machine will not back up partitions that are not formatted Mac OS Extended (i.e. HFS+). Therefore, the dual-boot partition will not be backed up automatically. Having said that, programs that back up the entire drive including the partitions should typically used for a one-shot cloning of an entire drive and not for regular backup, in my opinion. A great backup tool if your dual-boot OS is Windows is Winclone. Use it in combination with Time Machine and your system should be sufficiently backed up. Despite the picture below showing Macintosh HD, Winclone specializes in FAT32/NTFS partitions.
I know you've already accepted the answer, but a few notes;
(1) I would suggest now (and in the future) adding the details in your comment also into the first post. It's easier for new comers to jump in.
(2) Time Machine will back up two Mac (HFS+) partitions, but the story is completely different if they're FAT (neutral), EXT3 (Linux), or NTFS (Windows). These details about what the two partitions are matter heavily.
(3) In regards to the specific example of backing up source files, I've never liked that, as it always seems to get very kludgy very fast. A private repository hosted by a premium source code repository provider kept continually in sync is a wonderful off-site backup. Examples; GitHub, BitBucket, and... forgive me but I can't think of an SVN host that allows private repositories. Potentially SourceForge but I don't know first hand.