I want to recreate the text of a logo I have.
It had black half way down the text and then yellow for the other half.
How do I create text with a different colour on each half in Adobe Illustrator?
You can easily do this with a Gradient (without a gradient appearance). Don't let the term "Gradient" throw you. It's just the name of the tool, it doesn't have to mean a smooth transition between colors.
Just make certain the
Location for both gradient stops is set the same.
You can even make this dynamic while keeping text live. So, it moves with the text, if the text is edited. See here: Editable two side text
The text will function as the clipping mask. It will also still be editable! To edit the text or fine tune the position of the colours (rectangles), just double click on the group, like you do with any other clipping group.
There are many ways, here is one that would be much better if you wanted to change pieces of text on either side rather than half and half. For the most basic needs this is overkill.
Object > Expand in the top menu.
Create a line across the middle of the text where you want the colours to meet with this tool
(optional) Create a new layer to make it easier to manage parts afterwards by clicking on the
Layer panel and selecting the icon circled in red in the following screenshot.
Live Paint Bucket, found in the left tool menu like so or press K for the shortcut:
When you hover over the text and line they should change colour and come up with the message 'Click to make a Live Paint Group` do so.
Now when you hover over it should come up with outlines around shapes that are broken anywhere that a path intersects with another, like so:
Colour in the segments you want to and enjoy! :)
Another way, just for fun:
Note: You can also play with the size of the swatch using the Scale window (Menu->Object->Transform->Scale...). Again, tick off "Transform Objects" and tick "Transform Patterns".