Please help!

For some reason, a book that I read as a teen has come back to me in pieces and I am desperate to find it and reread it. I know it may not have the same magic as when I was the target audience, but I cannot get my mind off it. The problem is, I can’t for the life of me remember the title, or the author. All I have is snippets of plot. So I’m hoping if I explain what I can remember, one of you will have read it and can help me out.

So, it is about a young boy who has this magic book. I think when he lies, it appears in ink on the page. I remember being infuriated that he didn’t just make statements to learn things about the universe, or the kids that were picking on him. Honestly, that’s all I remember. Please help!