This could be done, but is a little complicated to do well, or economically.
The simplest was would for the button press to move a cylindrical lens into the beam, this will give you a line instead of a spot. The problem is that the length of the line will depend on how far away you stand from the screen, and if you want to limit the length of the line you might have to also adjust an aperture that would help provide that limit. That is the cheap solution.
More expensive you could have different line generator optics with different angular spread. You would still have the problem of the line being longer the farther away you are from the screen, but you could then switch between different lengths by switching different optics into position.
More complicated you could put a scanner in the laser pointer, that would rotate, or wiggle back and forth mechanically to move the spot in a line. This is hard to make small and depending on what you want to do a little complicated electronically.
There are lots of holographic optics that can be designed to produce different patterns, lines, circles, images etc that are pretty compact, but most will also have a lot of other little dots that may or may not be seen depending on how bright the presentation room is.