File indexing completed on 2024-04-28 09:37:04

0001 # Copyright 2014 Alex Merry <alex.merry@kde.org>
0002 #
0003 # Permission to use, copy, modify, and distribute this software
0004 # and its documentation for any purpose and without fee is hereby
0005 # granted, provided that the above copyright notice appear in all
0006 # copies and that both that the copyright notice and this
0007 # permission notice and warranty disclaimer appear in supporting
0008 # documentation, and that the name of the author not be used in
0009 # advertising or publicity pertaining to distribution of the
0010 # software without specific, written prior permission.
0011 #
0012 # The author disclaims all warranties with regard to this
0013 # software, including all implied warranties of merchantability
0014 # and fitness.  In no event shall the author be liable for any
0015 # special, indirect or consequential damages or any damages
0016 # whatsoever resulting from loss of use, data or profits, whether
0017 # in an action of contract, negligence or other tortious action,
0018 # arising out of or in connection with the use or performance of
0019 # this software.
0020 
0021 import gdb.printing
0022 from qt5printers import core
0023 
0024 """Qt5 Pretty Printers for GDB.
0025 
0026 The printers are split into submodules, one for each Qt library. Each
0027 submodule has a "printer" attribute that contains a pretty-printer for
0028 that library.
0029 """
0030 
0031 def register_printers(obj):
0032     """Registers all known Qt5 pretty-printers."""
0033     gdb.printing.register_pretty_printer(obj, core.printer)