Version 6.1.0.2, tag libreoffice-6.1.0.2
[LibreOffice.git] / basctl / source / basicide / linenumberwindow.hxx
blob81aaa8d93a008e392590166c3a266a2dc44d284a
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #ifndef INCLUDED_BASCTL_SOURCE_BASICIDE_LINENUMBERWINDOW_HXX
11 #define INCLUDED_BASCTL_SOURCE_BASICIDE_LINENUMBERWINDOW_HXX
14 namespace basctl
17 class ModulWindow;
19 class LineNumberWindow : public vcl::Window
21 private:
22 VclPtr<ModulWindow> m_pModulWindow;
23 int m_nWidth;
24 long m_nCurYOffset;
25 int m_nBaseWidth;
26 virtual void DataChanged (DataChangedEvent const& rDCEvt) override;
28 protected:
29 virtual void Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect) override;
31 public:
32 LineNumberWindow (vcl::Window* pParent, ModulWindow* pModulWin);
33 virtual ~LineNumberWindow() override;
34 virtual void dispose() override;
36 void DoScroll( long nVertScroll );
38 bool SyncYOffset();
39 long& GetCurYOffset() { return m_nCurYOffset;}
41 int GetWidth() { return m_nWidth;}
44 } // namespace basctl
46 #endif // INCLUDED_BASCTL_SOURCE_BASICIDE_LINENUMBERWINDOW_HXX
48 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */