From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 83B7D385841D for ; Mon, 7 Mar 2022 20:08:33 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 83B7D385841D Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-347-PcdnV7STPb2labihrQHzKg-1; Mon, 07 Mar 2022 15:08:32 -0500 X-MC-Unique: PcdnV7STPb2labihrQHzKg-1 Received: by mail-wm1-f71.google.com with SMTP id 14-20020a05600c104e00b003897a167353so71548wmx.8 for ; Mon, 07 Mar 2022 12:08:31 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:in-reply-to:references:date :message-id:mime-version; bh=rI+Y35+16+xVhN/kRp2Wh4uGGbKuNtZU5u2u21zg1rk=; b=0+u24xAL2PxT6E9o3PDmERQoEjyDjlHsiIFiFxfgfpIlxwVr5sjhmaoRrU70hLHHpG b8WIhsapcfOTKOxBF3UQ5tzElv+tA9SMnWmWeJYZnFEwJ6IpTRPFtQ9CdHgI50PLfROp nkiikTzsiZWXJIQPWU7GIXLN/vyQJqWjAy58ojts4b0zsJEKMkm0UBCNxE+pe2VZCZGm 1fFyVgVXzN7Ke1dvdJcbShiqZ4paLtYdv61k1tI4NBYTUvidA95APxWugTWSa5iotQyg 1aROeaNaG5pUXool9kceQfC7qSZvOaitCyjZFVcDp92JnSs+qB/MWMFSi5711p4Ok3Yr F/DQ== X-Gm-Message-State: AOAM532XIJuMYt5MIh1lpWzV78ez0iqBI/s9TFIDzhPxCBhYoMimYm0k 7mzwltW8pTfDEIreHts2KRGi5hLBrpdi+a3O9qZFlp5Z2/uV7BZvbW4vMucHBzslR3+xdpjJFaz NUtVdjd5u0Sybzdarm6T92g== X-Received: by 2002:adf:dbd2:0:b0:1ea:9382:6bff with SMTP id e18-20020adfdbd2000000b001ea93826bffmr9329485wrj.705.1646683710424; Mon, 07 Mar 2022 12:08:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJxJ2/kXj+JrhfCasSj7ekjF7YccbBKFHgamCHMR5WSiqFRvQF2n9cd3C/ofh/8blRxY9dO5xg== X-Received: by 2002:adf:dbd2:0:b0:1ea:9382:6bff with SMTP id e18-20020adfdbd2000000b001ea93826bffmr9329480wrj.705.1646683710262; Mon, 07 Mar 2022 12:08:30 -0800 (PST) Received: from localhost (host86-134-151-205.range86-134.btcentralplus.com. [86.134.151.205]) by smtp.gmail.com with ESMTPSA id g12-20020a5d698c000000b001f1d8bb4618sm13856428wru.36.2022.03.07.12.08.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Mar 2022 12:08:29 -0800 (PST) From: Andrew Burgess To: Tom Tromey , Andrew Burgess via Gdb-patches Subject: Re: [PATCHv2 14/15] gdb/tui: relax restrictions on window max height and width In-Reply-To: <87ilstskgd.fsf@tromey.com> References: <87ilstskgd.fsf@tromey.com> Date: Mon, 07 Mar 2022 20:08:29 +0000 Message-ID: <87ilspwmo2.fsf@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-5.1 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Mar 2022 20:08:34 -0000 Tom Tromey writes: >>>>>> "Andrew" == Andrew Burgess via Gdb-patches writes: > > Andrew> int > Andrew> tui_win_info::max_height () const > Andrew> { > Andrew> - return tui_term_height () - 2; > Andrew> + return tui_term_height (); > > I suspect this kind of thing is to ensure there's room for the box. > It's also possible this is just ancient code. Despite the big TUI > refactorings, there's still some leftover weird stuff in there. Maybe it was once, but I assume that if it was still needed then I'd see issues once it was removed. And I don't. As far as I understand things, the layout algorithm takes tui_term_height and assigns that space out to the container windows. The space allocated to a window is expected to include the windows border. So limiting the max window size like this just means we can never have a single window fill the terminal. I'll do more testing while I'm addressing the other feedback issues, and if you have any suggestions for things to try that might reveal a bug related to this change, then I'm happy to give it a go. But otherwise, as far as I can tell, the above change is fine. Thanks, Andrew