aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/color_utils.cpp
AgeCommit message (Collapse)AuthorFilesLines
2016-06-05Qt ui code: fix qreal type problems on ARM platformZdeněk Žamberský1-1/+1
fixing problems in qt ui code comming from the fact that qreal type is float on ARM platform and double on other platforms, which causes build errors on ARM (not all casts are probably strictly necessary) Bug: 12483 Change-Id: Ife5e6d3649a7ee1ad4e7eadffe9f4484ff2718de Reviewed-on: https://code.wireshark.org/review/15723 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-05-25Qt: Add Time and Comment labels to the sequence diagram.Gerald Combs1-18/+52
Add "Time" and "Comment" labels to the sequence diagram similar to the GTK+ UI. Draw a border around the diagram as well. Widen the default spacing and set it to a simple em-width multiple. Fix our port number alignment. Copy over the sequence diagram colors from the GTK+ UI and add them to ColorUtils. Color sequences according to their respective conversation numbers. To do: - Add zoom. Ping-Bug: 12419 Change-Id: I3f9b4ffbfcc34aae1c38e303cd36ff207be247b1 Reviewed-on: https://code.wireshark.org/review/15554 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-01-01No need for toolkit-dependent color initialization.Guy Harris1-0/+15
We're not allocating colors ourselves in GTK+ (and haven't been doing so since at least 1.12), and all color_t values are valid colors, so we don't need any toolkit-specific processing to fill in a color_t. While we're at it, catch read errors when reading color filter files. Change-Id: Ieb520d141cf15e371a31a01459d466c95ba2209b Reviewed-on: https://code.wireshark.org/review/12985 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-01Get rid of the "pixel" member of a color_t.Guy Harris1-1/+0
Now that we're letting GTK+/GDK allocate colors behind the scenes, if it allocates them at all, there's no reason to save the allocated color in the toolkit-independent color value. Change-Id: I99df32bd6b07924f41f3d855d2ddecb3dc8d5201 Reviewed-on: https://code.wireshark.org/review/12983 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-28Refactor GUI dependencies out of color_filters.[ch] and move it to epan ↵Michael Mann1-22/+0
directory. This also moved color.h into color_filters.h Change-Id: Ic19e27aa1b3ec67e764aa7ee8bbef7b1187bb12e Reviewed-on: https://code.wireshark.org/review/12831 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-10-08qt: add initialization of variable (CID 1311960)Dario Lombardo1-0/+1
Change-Id: I25bae2899f19982ee52c5ffb933a1459897b933b Reviewed-on: https://code.wireshark.org/review/10864 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-07-16Draw packet colors in the packet list scrollbar.Gerald Combs1-1/+1
Inspired by (but not as fancy as) Packet Fence, an enhancement written for Ethereal a loooong time ago by Martin Visser: https://www.wireshark.org/lists/ethereal-dev/200011/msg00122.html Several text editors call this a "minimap". Color each scrollbar raster line to match the color of up to 7 packets. Note in the comments why this number was chosen. If we have any flagged frames (marked, ignored, time ref) indicate them on either side of the scrolbar. Handle HiDPI (retina) displays. This means that your window size depends on the height of your scrollbar *and* your monitor resolution. Qt's idea of the slider rect doesn't match up with the slider on OS X. This might be local to my build -- I can replicate it Qt Creator. Change-Id: Ia089d2d766ce37bab11e22d1a5721b4908935304 Reviewed-on: https://code.wireshark.org/review/8982 Reviewed-by: Gerald Combs <gerald@wireshark.org> Tested-by: Gerald Combs <gerald@wireshark.org>
2015-07-16Add the RTP Stream Analysis dialog.Gerald Combs1-1/+19
Combine the GTK+ RTP Stream Analysis and RTP Graph Analysis dialogs into one. Yell at the user less. Disable the Analyze RTP Stream menu item if we don't have an RTP stream selected. There are a *lot* of moving parts in this dialog. I've tested with the few RTP captures I have but it's by no means complete. "To do" items are listed at the top of rtp_analysis.cpp. Change-Id: Id503977f069bebc46cc68bc749f0c9cbf4d37bf6 Reviewed-on: https://code.wireshark.org/review/9650 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-08Expert Info dialog.Gerald Combs1-0/+8
Show all expert messages in a combined view. Group top-level items by a (severity, group, protocol) tuple. Let the user enable and disable messages via a check menu. Add ProtoTree::goToField and expert_info_t.hf_index. Use them to jump to what we hope is the afflicted item. Enable the context menu only if the user has selected a packet item. Add a free-form search field that matches expert summaries. This differs from the GTK+ version but hopefully provides a smoother workflow. Bug: 10931 Change-Id: Ia12cb7c27cdea1634fa2798fb7e4c1b23bd16ad2 Reviewed-on: https://code.wireshark.org/review/8294 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-02-07Qt: Add the Coloring Rules dialog.Gerald Combs1-0/+10
Merge in the old ColorDialog which was a placeholder for color_filter_add_cb. Change-Id: I48d188509f480b8514122b4011ac9d8790fcca10 Reviewed-on: https://code.wireshark.org/review/6996 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-10-25Qt: ByteViewText fixups.Gerald Combs1-0/+20
Calculate our X coordinate using floating point arithmetic. This should hopefully fix the wierd subpixel text shifting for some font sizes. Add alpha blending convenience routines to ColorUtils. Use them to create the offset colors. The button color palette wasn't working very well under Ubuntu. Use QFontMetricsF::lineSpacing for our line height. Note that we don't support the BOLD gui.hex_dump_highlight_style preference. Leave a hint for anyone wishing to do so. Comment out related code for now. Change-Id: Ief77c9c8d00e05560cae6ecd781bd309027f6f5a Reviewed-on: https://code.wireshark.org/review/4927 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2013-10-15Add some missing parenthesis. Make sure we set our font in the right place.Gerald Combs1-0/+5
Make the ColorUtils::fromColorT() convenience function a little more convenient. Use it. svn path=/trunk/; revision=52620
2013-01-24Add font and color preferences. Unfortunately Qt doesn't have a colorGerald Combs1-7/+7
picker widget so we're back to popping up dialogs. Move the contents of monospace_font.{cpp,h} to wireshark_application.{cpp,h}. Pango and Qt use completely different string representations for fonts. Add a separate gui.qt.font_name preference so that they don't clobber each other. svn path=/trunk/; revision=47240
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45017
2012-09-04Add modelines for Qtshark fileAlexis La Goutte1-0/+13
svn path=/trunk/; revision=44766
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-01-04Add initial support for Qt along with a "ui" subdirectory.Gerald Combs1-0/+60
svn path=/trunk/; revision=40378