octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Patches for autopositioning of labels in fltk


From: Ben Abbott
Subject: Re: Patches for autopositioning of labels in fltk
Date: Fri, 17 Dec 2010 22:24:39 -0500

On Dec 17, 2010, at 3:58 PM, logari81 wrote:

> On Tue, 2010-12-14 at 19:25 -0500, Ben Abbott wrote:
>> On Dec 14, 2010, at 2:42 PM, logari81 wrote:
>> 
>>> A very simple solution that I have tried in the frontend is adding a
>>> __fltk_redraw__()
>>> just after the set() call in __axis_label__.m . At least on my
>>> installation it seems to work fine with your test script.
>>> 
>>> I could easily implement the same in the backend as well. But it is a
>>> bit more difficult to achieve finer control of the situation and request
>>> only the modified axis to be redrawn.
>>> 
>>> What do you think? Do you see any performance issues due to excessive
>>> redraw calls?
>>> 
>>> Kostas
>> 
>> This is too far out of my sandbox for me to offer an informed opinion.
>> 
>> So, I've cc'd some of the developer's who have contributed to the OpenGL 
>> backend.
>> 
>> Ben
>> 
> 
> I have prepared a summary of the changes that we have discussed in this
> thread and rebased the corresponding changesets onto the current
> revision of octave. I think that the first two of the attached
> changesets should be adopted independently of the the third one.
> 
> 1. The first changetset sets the default axis labels size from 12 to 10.
> 
> 2. The second changeset permits the user to manually set the position
> and rotation of the axis labels and title in the fltk backend.
> 
> 3. The third one fixes:
>> px = get (xlabel ('hello world'), 'position')
>> px =   0   0   0
> This error also occurs with the current octave version, so is not
> related to the previous two patches, so the adoption of the third patch
> shouldn't be a blocker for the first two.
> 
> Regards
> 
> Kostas
> <1_axes-default-fontsize.changeset><2_no-label-autopositioning-if-manual.changeset><3_redraw-axes-after-label-set.changeset>

I've pushed the first two changesets. For the 3rd is it no necessary to check 
that the flkt backend is active?

Does something like the following be included in __axis_labels__.m ?

        if (strcmp (get (ancestor (ca, "figure"), "__backend__"), "fltk"))
          __fltk_redraw__ ();
        endif

Ben



reply via email to

[Prev in Thread] Current Thread [Next in Thread]