If you are experiencing sore eyes you should talk to an eye doctor for a complete check up. You might need prescription glasses.
Many people say that taking breaks to look at things further away than a computer screen (like trees outdoors) is very helpful. If after the doctor gives you an all-clear, and you would like to try blue light blocking glasses, the SCT Orange glasses from Uvex are $10 and block most of the wavelengths that affect sleep.
If you are experiencing an unexpected color change at night using f.lux (I see that you have your program set to remain dim and orange all day), there are two things to try:
check if you can update f.lux
check if you can update your video drivers.
A discussion about sleep, light, wellness, circadian clocks
I think this is a key question because avoiding all light during the day can make sleep problems worse, and in some cases this might make headaches the next day worse as well (because you didn't sleep well or because your circadian system is not expecting bright light at certain times).
Overall I would say two things:
If you have really bad headaches "right now", I would do what you need to. Avoiding bright light is a great approach, and trying to increase light levels later in the day is sometimes possible too.
On most other days, most people should try to see enough bright "blue" light during the day (e.g., an hour outdoors) and keep things dimmer at night. This will let you sleep a little better at night, and if you do, maybe it will help headaches too.