diff options
author | inferno@chromium.org <inferno@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-09 17:02:09 +0000 |
---|---|---|
committer | inferno@chromium.org <inferno@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-09 17:02:09 +0000 |
commit | d151a5ef5e357e7d7187fcc1aa8fbb6c31f223cb (patch) | |
tree | bfb7e9b3484915c8e85bb2d8f91c4ee038cbf611 /chrome | |
parent | 1a5971973b9b19d413831d2d6206770aa3529775 (diff) | |
download | chromium_src-d151a5ef5e357e7d7187fcc1aa8fbb6c31f223cb.zip chromium_src-d151a5ef5e357e7d7187fcc1aa8fbb6c31f223cb.tar.gz chromium_src-d151a5ef5e357e7d7187fcc1aa8fbb6c31f223cb.tar.bz2 |
Fix eliding, truncation issues with hostnames in security information dialog for windows, linux platforms resp.
BUG=48597
TEST=None
Review URL: http://codereview.chromium.org/2958002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51972 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/gtk/page_info_window_gtk.cc | 3 | ||||
-rw-r--r-- | chrome/browser/views/page_info_window_view.cc | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/chrome/browser/gtk/page_info_window_gtk.cc b/chrome/browser/gtk/page_info_window_gtk.cc index ada3f81..ceefbe2 100644 --- a/chrome/browser/gtk/page_info_window_gtk.cc +++ b/chrome/browser/gtk/page_info_window_gtk.cc @@ -165,6 +165,9 @@ GtkWidget* PageInfoWindowGtk::CreateSection( label = gtk_label_new(UTF16ToUTF8(section.description).c_str()); gtk_misc_set_alignment(GTK_MISC(label), 0, 0); gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); + // Allow linebreaking in the middle of words if necessary, so that extremely + // long hostnames (longer than one line) will still be completely shown. + gtk_label_set_line_wrap_mode(GTK_LABEL(label), PANGO_WRAP_WORD_CHAR); gtk_box_pack_start(GTK_BOX(text_box), label, FALSE, FALSE, 0); gtk_widget_set_size_request(label, 400, -1); diff --git a/chrome/browser/views/page_info_window_view.cc b/chrome/browser/views/page_info_window_view.cc index dbc790c..ea573d8 100644 --- a/chrome/browser/views/page_info_window_view.cc +++ b/chrome/browser/views/page_info_window_view.cc @@ -369,6 +369,9 @@ Section::Section(const string16& title, description_label_ = new views::Label(UTF16ToWideHack(description)); description_label_->SetMultiLine(true); description_label_->SetHorizontalAlignment(views::Label::ALIGN_LEFT); + // Allow linebreaking in the middle of words if necessary, so that extremely + // long hostnames (longer than one line) will still be completely shown. + description_label_->SetAllowCharacterBreak(true); AddChildView(description_label_); } |