How can i fix this pane size?

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

How can i fix this pane size?

Post by vivekpatel »

Hello,
here i am attaching image that show pane.
User avatar
Will - Tracker Supp
Site Admin
Posts: 6815
Joined: Mon Oct 15, 2012 9:21 pm
Location: London, UK
Contact:

Re: How can i fix this pane size?

Post by Will - Tracker Supp »

Hi Vivek,

Thanks for the post, but it appears that the image did not upload. Please make sure that it is wraped in a RAR, 7Zip, or ZIP archive.

Thanks,
If posting files to this forum, you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded.
Thank you.

Best regards

Will Travaglini
Tracker Support (Europe)
Tracker Software Products Ltd.
http://www.tracker-software.com
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,
how to fix pane size?
Attachments
pane.rar
(661.54 KiB) Downloaded 118 times
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How can i fix this pane size?

Post by Sasha - Tracker Dev Team »

Hello vivekpatel,

Please clarify what do you mean exactly - do you want to make the pane non-resizable or do you want to set it's predefined size?

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
User avatar
Vasyl-Tracker Dev Team
Site Admin
Posts: 2353
Joined: Thu Jun 30, 2005 4:11 pm
Location: Canada

Re: How can i fix this pane size?

Post by Vasyl-Tracker Dev Team »

Hi vivekpatel.

Try to use this code when document is opened:

Code: Select all

Int64 addFlags = 
PDFXEdit.UIX_LayoutStyleFlags.UIX_LayoutStyle_PanesNoClose | 
PDFXEdit.UIX_LayoutStyleFlags.UIX_LayoutStyle_PanesNoReorder | 
PDFXEdit.UIX_LayoutStyleFlags.UIX_LayoutStyle_StaticSplitters;

doc.ActiveView.Panes.Layout.Obj.SetStyle(addFlags, addFlags);
HTH.
Vasyl Yaremyn
Tracker Software Products
Project Developer

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,

Its works but i want pagesview small like thumbnailview and thumbnailview like pagesview?
So what to do?
Attachments
thumb.rar
(940.2 KiB) Downloaded 111 times
User avatar
Vasyl-Tracker Dev Team
Site Admin
Posts: 2353
Joined: Thu Jun 30, 2005 4:11 pm
Location: Canada

Re: How can i fix this pane size?

Post by Vasyl-Tracker Dev Team »

The working code to do that:

Code: Select all

PDFXEdit.IUIX_LayoutItem itm = doc.ActiveView.Panes.Layout.GetItem(doc.ActiveView.PageThumbsView.Obj);
if (itm != null)
{
    itm.Show();

    // lookup for first tabbed-container (by default the 'Thumbnails' pane is inside the special tabbed container that contains 'Bookmarks', 'Comments', 'Contents' and others too)
    PDFXEdit.IUIX_LayoutItem p = itm.Parent;
    itm = null;
    while (p != null)
    {
        if ((p.Style & (int)PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_Splitted) == 0)
        {
            itm = p;
            break;
        }
        p = p.Parent;
    }

    if (itm != null)
    {
        doc.ActiveView.Panes.Layout.LockUpdates();
        int addFlag = (int)PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_FixedSize;
        itm.SetStyle(addFlag, addFlag);
        PDFXEdit.tagSIZE sz;
        sz.cx = sz.cy = 500; // set custom size here of pane (width will be changed in our case)
        itm.set_FixedSize(sz);
        doc.ActiveView.Panes.Layout.UnLockUpdates();
    }
}
HTH.
Vasyl Yaremyn
Tracker Software Products
Project Developer

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,
==========================
Dim itm As PDFXEdit.IUIX_LayoutItem = doc.ActiveView.Panes.Layout.GetItem(doc.ActiveView.PageThumbsView.Obj)
If itm IsNot Nothing Then
itm.Show()
Dim p As PDFXEdit.IUIX_LayoutItem = itm.Parent
While (p IsNot Nothing)
If (p.Style And PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_Splitted = 0) Then
itm = p
Exit While
End If

p = p.Parent
End While

If itm IsNot Nothing Then
doc.ActiveView.Panes.Layout.LockUpdates()
Dim flag As Integer = PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_FixedSize
itm.SetStyle(flag, flag)
Dim sz As PDFXEdit.tagSIZE

sz.cx = sz.cy = 1000
itm.FixedSize = sz
doc.ActiveView.Panes.Layout.UnLockUpdates()

End If


End If
===========================

This code not working. In vb.net there is no properties to set itm size. So what to do?
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How can i fix this pane size?

Post by Sasha - Tracker Dev Team »

Hello vivekpatel,

Please try using itm.set_FixedSize(sz); not itm.FixedSize = sz;

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,

"itm.set_FixedSize(sz)" not working.
Attachments
fixedsize.rar
(216.9 KiB) Downloaded 109 times
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How can i fix this pane size?

Post by Sasha - Tracker Dev Team »

Hello vivekpatel,

It seems there is some kind of a problem with vb.net, because the C# version is working correctly. We will investigate and inform you when we have a solution available.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,

i'm looking forward to it.
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17948
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: How can i fix this pane size?

Post by Tracker Supp-Stefan »

Thanks for the patience and understanding vivekpatel!

Sasha will post back here as soon as possible!

Cheers,
Stefan
User avatar
Vasyl-Tracker Dev Team
Site Admin
Posts: 2353
Joined: Thu Jun 30, 2005 4:11 pm
Location: Canada

Re: How can i fix this pane size?

Post by Vasyl-Tracker Dev Team »

Hi, vivekpatel.

We found one issue in your vb code. Please change the:

If (p.Style And PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_Splitted = 0) Then ...

to:

If ((p.Style And PDFXEdit.UIX_LayoutItemStyleFlags.UIX_LayoutItemStyle_Splitted) = 0) Then ...

and code-sample will work as well..

The proof:
https://msdn.microsoft.com/en-us/library/fw84t893.aspx

HTH
Vasyl Yaremyn
Tracker Software Products
Project Developer

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
vivekpatel
User
Posts: 141
Joined: Sat Aug 27, 2016 11:00 am

Re: How can i fix this pane size?

Post by vivekpatel »

Hello,

I do that. But what about "itm.set_Fixedsize"??
Thanks.
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: How can i fix this pane size?

Post by Sasha - Tracker Dev Team »

Hello vivekpatel,

Just use the itm.FixedSize = sz with the Vasyl's fixes applied in your previous code and everything should work.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Post Reply