As a screenwriter, the bottom line is you are part of the entertainment industry. However high-brow your subject matter may be, people watch movies in order to have some kind of visceral rather than intellectual experience. They want to be entertained.
Regardless of whether you’re talking about a Hollywood blockbuster or a lo-budget art house film, or even a feature-length documentary, audiences pay to be frightened, amused, romantically stimulated, outraged, and so on, not to get an academic education. They want to be entertained.
A movie can express a moral point of view, pose hypothetical questions, explore historical events, personal relationships, social conventions, and so on. Whether it does so through drama or comedy, the audience only agrees to watch the film in the first place because they expect an engaging, emotional cinematic experience. They want to be entertained.
The word entertainment has had a lot of bad press. It’s mostly equated with superficial distraction. Look at what the dictionaries have to say: “To cause the time to pass pleasantly … to amuse … to divert …” (Webster's). “To amuse, to occupy agreeably,” (Oxford). “To provide amusement for …” (Collins).
But wait, put your judgemental, artistic indignation on hold for a moment and acknowledge a simple fact: The function of entertainment is to direct someone’s attention to something enjoyable. Again, “enjoyable” here refers to the full gamut of emotional cinematic experience, ranging from hilarity to terror. That, on the face of it, is the screenwriter’s job. Write stuff that people want to watch, for whatever reasons they may have.
Of course, the trick is to give the audience something enjoyable to watch, and while they’re not looking, slip in under their radar.
Or if you prefer a more classical metaphor: The job of the screenwriter is to write Trojan horses.
In other words, a film has to be entertaining (in the broadest sense of the term) to earn and maintain the audience’s attention so that you can tell them something that is anything but entertaining.
How you achieve this? The same way painters, musicians, composers and all other creative artists do, by mastering existing techniques in order to be able to subvert them. For the screenwriter that means getting a good understanding of what makes films entertaining: Genre conventions, pacing, structure and all the other “technical” aspects of screenwriting.
I could be wrong, but it seems to me that mastering the “entertaining” part of screenwriting is just as important as getting the “enlightening” aspect right.