Easiest would be to use a PWM - Component and configure it accordingly. Have a look at the PWM's datasheet.

The way you showed in your example differs a bit from the way PSoCs work: Usually you do not need to access ports or pins directly, there are many pre-defined components: timers, PWM, counter, interfaces and you just have to configure them at design-time and start them with an API at run-time preferrably in c-language.

In the parameters window of PWM8 user module, set the "compare out" as Row0_Output0. Then, click on LUT on that row and click on the buffer which connects to GlobalOutEven4 (GOE 4). Then click on globalOutEven4 line and select the "pin" as P0[4].