bugGNU TeXmacs - Bugs: bug #41021, Widget cache in tm_window_rep...

 
 

You are not allowed to post comments on this tracker with your current authentification level.

bug #41021: Widget cache in tm_window_rep always misses

Submitted by:  Miguel de Benito <mdbenito>
Submitted on:  Sat 28 Dec 2013 04:22:25 PM UTC  
 
Category: User InterfacePriority: 5 - Normal
Item Group: ErrorStatus: Confirmed
Privacy: PublicAssigned to: Joris van der Hoeven <vdhoeven>
Originator Name: Open/Closed: Open
Release: Release: None
Fixed Release: NoneFixed Release: 
Keywords: 

Sat 28 Dec 2013 04:32:49 PM UTC, comment #1:

Use the attached patch to see that it is indeed a problem with the "raw" procedures. It is not intended as a workaround!

(file #30122)

Miguel de Benito <mdbenito>
Project Member
Sat 28 Dec 2013 04:22:25 PM UTC, original submission:

To test:

  • Uncomment the debug messages in tm_window_rep::get_menu_widget
  • type a backslash in a TeXmacs document
  • Move in and out of the newly created tag in order to see the focus bar change.
  • See how the cache misses constantly and grows with each cursor movement.

The reason:

The cache implemented for the toolbars in tm_window_rep::get_menu_widget uses the object returned by a scheme call to menu-expand as a key. Sometimes the object contains "raw" procedures which fail the equality test for the hash.

This happens whenever the menu being expanded contains plain buttons, i.e. when the following scheme syntax is used for a toolbar:

This is the case in the focus-tag-menu when the focus tree has no variants (see generic-menu.scm). The expanded menu then contains "raw" procedures, as in:

Even if the procedures are the same between two calls, these are not recognized by the equality operator.

Miguel de Benito <mdbenito>
Project Member

 

Attached Files
file #30122:  test.patch added by mdbenito (1kB - application/octet-stream - This patch shows that it is indeed a problem with the "raw" procedures in the expanded menu)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by mdbenito (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 28 Dec 2013 04:32:49 PM UTCmdbenitoAttached File-=>Added test.patch, #30122

    Back to the top


    Powered by Savane 3.1-cleanup