I'm not sure how KStars does it, and I'm glad Hy knows. But my general experience with FITS is that asinh scaling works best. You can search the internet for how that works and there's some documentation. BTW, SAOImage DS9 has a bunch of scalings you can try.