You do so just like you resize any other partition; however, you'll find it easier to click on its list entry than its entry in the diagram above the partition list.
Keep in mind, however, that most text-mode tools resize either partitions or file systems, but not both; you must combine both types of tools to resize a partition and its file system.
If you want to take space from a logical partition to give it to a primary partition or vice versa, you must explicitly resize the extended partition that surrounds the logical partitions.