0) Changing partitions is risky. Please make a backup of your data, then verify the backup matches the source data; then backup again to a different drive or cloud, verify that matches the source, and only then start with partition changes.
00) Make one change at a time with gparted. After you specify a change (e.g., deleting the swap partition, if you decide that's OK), then click on the green check mark at top center to commit that change. Change-commit, change-commit, change-commit.
1) You can't change things unless the partition you want to change is unlocked. In this case, you must boot from a LiveDVD or a LiveUSB, such as was used to install Ubuntu in the first place.
2) If you are using Ubuntu 18.04 or newer, and you do not use Hibernation, you can eliminate the Swap Partition /dev/sda5 and give its space to /dev/sda6, then create a Swap File once you finish changing the partitions. Otherwise, if you either use Ubuntu 16.04 or older, or use Hibernation, you have to delete the Swap Partition and recreate it at the beginning of the unallocated space.
3) Once you have moved or deleted the Swap Partition, then you can move your ext4 Ubuntu partition, /dev/sda6, forward into unallocated space.
4) Once the move completes, then expand the end of the ext4 partition to occupy all remaining unused space. Thanks to heynnema https://askubuntu.com/users/4272/heynnema for the advice!
sda5
) to the left. https://askubuntu.com/a/1176013/590937 – mook765 Nov 11 '19 at 19:04