Recent Posts

Pages: 1 2 3 4 [5] 6 7 8 9 10
Development / Re: event sequence question?
« Last post by Miguel Gimenez on January 16, 2022, 11:39:33 am »
I have added it to autotools in r12657, but I am not an autotools expert, so please review it.
Nightly builds / The 16 Januari 2022 build (12655) is out.
« Last post by killerbot on January 16, 2022, 10:57:36 am »
We switched to wx 3.1.5 --> download the new wx dll's see link below

Get quick announcements through the RSS feed

Before you use a nightly make sure you understand how it works.

A link to the unicode windows wxWidget dll(s) for Code::Blocks :
A link to Mingw64 dll's needed by Code::Blocks :

The 16 Januari 2022 build is out.
  - Windows :
  - Linux :

The current SDK version is : 2.16.0

Resolved Fixed:

  • Sort compiler list in compiler detection dialog.
  • Compiler: Use the same shell for cleaning and compiling makefiles (ticket #389
  • wxSmith: Fix compilation when wxUSE_STL=1 (ticket #873)
  • Allow removal from project of multiple selected files (ticket #116)
  • Add Jens Lody's DisplayEvent core plugin. (WIP)

Regressions/Confirmed/Annoying/Common bugs:

    Development / Re: event sequence question?
    « Last post by killerbot on January 16, 2022, 10:56:38 am »
    please activate it also in the autotools and indeed bring it up to date. in line with other project files, that would be great.
    Contributions to C::B / Re: Code::Blocks' translation
    « Last post by LETARTARE on January 16, 2022, 10:45:54 am »
    Thanks, your test is valuable.
    I had downloaded 'wx-315' sources on the 'WXWidgets' website and had compiled using 'gcc-810' without problem until this test.

    I will check everything today...
    Contributions to C::B / Re: Code::Blocks' translation
    « Last post by gd_on on January 16, 2022, 10:12:46 am »
    OK. So it's an other problem.
    I tried different things as :
    • using directly the .mo file downloaded from launchpad;
    • download the .po from launchpad, compiling it with poedit, and using the .mo produced (with and without renaming it)
    • using my own .mo file ...
    everything work as expected.

    I also tried to rename a .mo file in .po, just to see what happens. C::B logically appears in English : no assert message.

    So, I can't reproduce your behaviour.

    One idea : Are you sure you use a wxWidgets version compiled with the same compiler version as your Code::Blocks build ?

    There is also an other thing which look strange for me :
    at line 405 in menucmn.cpp (located in C:\wxWidgets-3.1.5\src\common for me), I have :
    wxMenuItemList::compatibility_iterator node = m_items.Item(pos);
    which does not correspond exactly to your indicated code lines. For me it's inside wxMenuBase::DoInsert (not in wxMenuBase::Insert)
    Assert lines are 403 or 406. So, may be we have not exactly the same wxWidgets 3.1.5 version !)

    Note : it's in wxWidgets 3.1.6 (trunk version, beta) that I have a wxcheck at line 405, inside wxMenuBase::Insert ! But, I still don't use it in C::B.
    Development / Re: event sequence question?
    « Last post by AndrewCot on January 16, 2022, 07:15:46 am »
    Under Linux the cbDisplayEvents-unix.cbp will not build as it has not been updated for wx30... and if you compare it to other unix project files there are a few other changes to bring it up to the current standard.
    Attached is the project file I have building. I have not tested it yet as it will take about another hour to get everything saved, re-built and quickly tested on Linux.
    Plugins development / Re: Code completion using LSP and clangd
    « Last post by Pecan on January 16, 2022, 07:14:00 am »

    Thanks for working on that. I'll give those changes a test tomorrow.
    Plugins development / Re: Code completion using LSP and clangd
    « Last post by ollydbg on January 16, 2022, 04:53:58 am »
    I make a clean git svn clone, and it looks like the clangd_client can be active now. I'm not sure why.

    I see that the changes in my previous post did solve the error message issue. Here is the whole patch I use.

     clangd_client/clangd_client_wx31_64.cbp    | 11 ++++++-----
     clangd_client/src/LSPclient/src/client.cpp |  4 ++--
     2 files changed, 8 insertions(+), 7 deletions(-)

    diff --git a/clangd_client/clangd_client_wx31_64.cbp b/clangd_client/clangd_client_wx31_64.cbp
    index 1af073c..eb3e6d4 100644
    --- a/clangd_client/clangd_client_wx31_64.cbp
    +++ b/clangd_client/clangd_client_wx31_64.cbp
    @@ -6,8 +6,8 @@
      <Option compiler="gcc" />
      <Target title="Clangd_Client-uw">
    - <Option output="bin/Clangd_Client" prefix_auto="1" extension_auto="1" />
    - <Option working_dir="bin31_64" />
    + <Option output="$(TARGET_DEVEL_DIR)/src/devel31_64/share/CodeBlocks/plugins/clangd_client" prefix_auto="1" extension_auto="1" />
    + <Option working_dir="$(TARGET_DEVEL_DIR)/src/devel31_64" />
      <Option object_output=".objs31_64" />
      <Option external_deps="$(CODEBLOCKS)/libcodeblocks.a;" />
      <Option type="3" />
    @@ -50,12 +50,13 @@
      <Add before="cmd /c @echo CODEBLOCKS: $(CODEBLOCKS)" />
      <Add before="cmd /c @echo TARGET_DEVEL_DIR: $(TARGET_DEVEL_DIR)" />
      <Add before="g++ --version" />
    - <Add after="cmd /c MakeRepoUpload.bat" />
    + <Add after="cmd /c if not exist $(TARGET_DEVEL_DIR)\src\devel31_64\share\CodeBlocks mkdir $(TARGET_DEVEL_DIR)\src\devel31_64\share\CodeBlocks" />
    + <Add after="zip -jq9 $(TARGET_DEVEL_DIR)\src\devel31_64\share\CodeBlocks\ src/resources/manifest.xml src/resources/*.xrc" />
    + <Add after="zip -r9  $(TARGET_DEVEL_DIR)\src\devel31_64\share\CodeBlocks\ src/resources/images" />
      <Mode after="always" />
    - <Variable name="TARGET_DEVEL_DIR" value="$(CODEBLOCKS)\..\.." />
    - <Variable name="TARGET_DEVEL_DIR_AC" value="D:\Andrew_Development\WorkingOnThese\AC-WindowsInstaller" />
    + <Variable name="TARGET_DEVEL_DIR" value="D:\code\cb\cb_sf_git\cccrash2019" />
    diff --git a/clangd_client/src/LSPclient/src/client.cpp b/clangd_client/src/LSPclient/src/client.cpp
    index 3aa6956..6ae6afa 100644
    --- a/clangd_client/src/LSPclient/src/client.cpp
    +++ b/clangd_client/src/LSPclient/src/client.cpp
    @@ -1053,7 +1053,7 @@ bool ProcessLanguageClient::DoValidateUTF8data(std::string& data)
                 char invChar = data[invloc]; // **debugging**
                 data[invloc] = ' '; //clear the invalid utf8 char
                 wxString msg = "Error: Removed clangd response invalid utf8 char:";
    -            msg << "\'" << invChar << "\'";
    +            msg << "\'" << wxString::Format("%x", invChar ) << "\'";
    @@ -1562,7 +1562,7 @@ bool ProcessLanguageClient::LSP_DidOpen(cbEditor* pcbEd)
         m_FileLinesHistory[pcbEd] = pCntl->GetLineCount();
         wxString strText = pCntl->GetText();
    -    const char* pText = strText.mb_str();           //works
    +    const char* pText = strText.ToUTF8();           // ollydbg 2022-01-16
         writeClientLog(wxString::Format("<<< LSP_DidOpen:%s", docuri.c_str()) );

    Note the change in :

    msg << "\'" << wxString::Format("%x", invChar ) << "\'";

    is also try to suppress a message alert box(an ascii char to wxString convert, but the invChar value is bigger than 127)
    Plugins development / Re: Code completion using LSP and clangd
    « Last post by ollydbg on January 16, 2022, 03:45:19 am »
    I see some code:

        wxString fileURI = fileUtils.FilePathToURI(infilename); //(ph 2022/01/5)
        fileURI.Replace("\\", "/");
        DocumentUri docuri = DocumentUri(fileURI.c_str());
        cbStyledTextCtrl* pCntl = pcbEd->GetControl();
        if (not pCntl) return false;

        // save current length of the file
        m_FileLinesHistory[pcbEd] = pCntl->GetLineCount();

        wxString strText = pCntl->GetText();
        const char* pText = strText.mb_str();           //works

        writeClientLog(wxString::Format("<<< LSP_DidOpen:%s", docuri.c_str()) );

        try { DidOpen(docuri, string_ref(pText, strText.Length()) ); }
        catch(std::exception &err)
            //printf("read error -> %s\nread -> %s\n ", e.what(), read.c_str());
            wxString errMsg(wxString::Format("\nLSP_DidOpen() error: %s\n%s", err.what(), docuri.c_str()) );
            return false;

    My guess is that:

    const char* pText = strText.mb_str(); 

    Is this correct?

    From my point of view, it should be:

    Final word of caution: most of these functions may return either directly the pointer to internal string buffer or a temporary wxCharBuffer or wxWCharBuffer object. Such objects are implicitly convertible to char and wchar_t pointers, respectively, and so the result of, for example, wxString::ToUTF8() can always be passed directly to a function taking const char*. However code such as

    const char *p = s.ToUTF8();
    puts(p); // or call any other function taking const char *

    This is from wx document here:

    Plugins development / Re: Code completion using LSP and clangd
    « Last post by ollydbg on January 16, 2022, 03:24:31 am »

    Well, I'm at a loss to figure out why that variable is false for you.

    Somehow, clangd_client is seeing Setting/Editor/Code completion as unchecked in your  CB .conf file.

    This has nothing to do with your .cbp file. It's the contents of the .conf file that the debugger is using that's causing this problem.

    Hi, Pecan, thanks for the help, I will try to debug this issue and see what happens in the code.
    Pages: 1 2 3 4 [5] 6 7 8 9 10