A cruise up the Bosporus is one of the prime attractions of any trip to Istanbul, so we took the lovely two-hour ride Sunday. And just as the boat traversed the European and Asian sides of the Turkish city, home to so many civilizations, so did our excursion ride the line between vacation and political action.

As we passed the shore-side mansions and old palaces, more than a dozen fishing boats rode by in formation. They were draped in red Turkish flags, political banners and pictures of Mustafa Kemal Ataturk, the founder of modern Turkey. Turkish passengers on our boat waved their arms or clapped in support.

The police had brutally shut down spontaneous street marches to the city’s Gezi Park the night before. But there appeared to be no way to stop the free expression on the waterway, and the effect was exhilarating.

Then came more boats, bigger yachts with their own Turkish flags, accompanied by the orange-and-white flags of the party of Prime Minister Recep Tayyip Erdogan. Huge banners bearing his pictures also flew. The men aboard the boats, who seemed to be in opposition to the fishing vessels, chanted and waved, as if cheering for a sports team. Some of the camera-toting riders on our excursion waved back. Perhaps they were government supporters, or maybe they were tourists like us, wanting to join in despite not knowing exactly what was going on.

We’d been planning our big family trip to Turkey for months. As the departure date approached, we followed the reports of battles in Istanbul — over what initially seemed to be a civic planning issue.

Acting more like the Istanbul mayor he once was instead of prime minister, Erdogan was pushing ahead with a plan to raze Gezi Park, which adjoins the central Taksim Square and is one of the last green spots in the city, and replace it with an Ottoman-style military barracks and shopping center.

Protesters had occupied the spot since the end of May, and police had cracked down with tear gas on more than one occasion. The latest such battle had occurred June 11, the day before our plane left for Turkey.

We had booked an apartment near the famed Galata Tower, which had seen the city change hands many times. It wasn’t far from Taksim Square, but it was far enough for us to assume that the protests there wouldn’t affect us if they didn’t die down.

It was clear fairly soon, however, that there was no way the unrest wouldn’t affect our trip. And instead of developing a taste for paprika or any other spice often used by Turks, I was about to learn about the properties of tear gas.

We spent our first day or so in the city visiting the checklist of must-sees, beginning with Topkapi Palace, where the sultans lived. At the Grand Bazaar, where aggressive salesmen could have taken advantage of the crisis, I didn’t see anyone hawking a pro or con T-shirt.

The exception to the quiet in tourist areas was the vivid graffiti, which seemed to be growing by the day. There were also drawings of fists and stencils of potted plants with closed-circuit-camera blooms — messages that posed no language barrier.

After the initial sightseeing, we were drawn to the other main attraction in the city: Taksim Square, a wide expanse of stone and concrete, and the protesters camped there. The tents and nonviolent demeanor had a familiar vibe — not unlike the eight-month Occupy D.C. encampment in McPherson Square, whose members removed the final tents a year ago this month.

The people in Taksim whom I spoke with were thoughtful and resolved, intending to make a point about capitalism’s march on public space.

Ringing the park, and with an especially strong presence in front of a government building adorned with two huge Turkish flags, were hundreds of police officers and dozens of vehicles, including a couple equipped with water cannons, apparently built for no other reason than to knock people down.

Hours after our visit Saturday morning, the police took action. We were away from the square and heard people banging pots and pans from out their windows in protest of the crackdown. Outrage grew from mere noisemaking to spontaneous marches up Istiklal Avenue, a popular pedestrian shopping street.

On Sunday, after our politically tinged cruise up the Bosporus, it was clear that something had changed in the city. Back on land, throngs in the street chanted and marched in gas masks, swim goggles and hard hats as the acrid smell of tear gas lingered. You feel the burn first at the bottom of your lungs. My eyes had been watering, but I’d assumed that it was a more common vacation malady: It was hot, and my sunscreen had melted.

We were up in the apartment again when we heard shots and people running. Tear gas filled the narrow street of coffee shops and clothing stores. There was a rush to shut windows.

While I had been on the Bosporus, the other half of my family had been thwarted in their attempt to see dervishes perform nearby. Crowds clogged the street; the museum shuttered early in defense. There would be no dervishes that day. Clearly we were all caught up in quite a different kind of whirling.

Catlin is a freelance writer based in Washington.